Saturday, 15 May 2010

in custom yeoman-generator include one template inside another -



in custom yeoman-generator include one template inside another -

all of template files i'm using in app/templates folder share mutual header @ top of each file, company name, license, copyright, etc. don't want re-create , paste files in templates folder. i'm trying figure out how set info in separate file , kind of include in other template files if have edit can in 1 place.

i've been searching illustration of how no luck far hope here has answer. thanks.

there's no back upwards partial templates currently.

what can instead providing parameter:

<%= license %> var = 1;

then in generator:

this.fs.copytpl(from, to, { license: getlicensecontent() });

templates yeoman partial yeoman-generator

No comments:

Post a Comment