2016-03-22 38 views
0

js dosya için Yeoman'da placeholder dosyasını nasıl kullanabilirim? i gerektiği yerde o Javascript dosyalarındaki Yeoman yer tutucu

writing: function() { 
    this.fs.copy(
     this.templatePath('portanova_template'), 
     this.destinationPath(this.projectName) 

    ); 
    if(this.answer) { 
     this.fs.copy(
     this.templatePath('externalTemplate'), 
     this.destinationPath(this.projectName+'/app'), 
     { 
     title: this.projectName 
     } 
    ); 
    } 
    }, 

ve js Dosya

sadece

"<%= title %>" 

eklendi eklemeye çalıştı. Ama işe yaramıyor .. Herhangi bir fikir?

cevap

1

this.fs.copyTpl()'u kullanmanız gerekir, aksi takdirde şablon etiketleri işlenmez.