lists
Closed this issue · 3 comments
yields commented
wanted to add something like:
channels: server, mobile, client
and have it render as:
var Integration = module.exports = integration('Integration')
.channels(['server', 'mobile', 'client']);
is this possible ?
ianstormtaylor commented
Good question. Not nicely right now, but it would be cool to add support for lists to the prompter, since that seems like a pretty solid addition.
I thiiiiink it's technically possible right now if you get real weird with it:
[{{#server}}'server'{{#mobile}},{{/mobile}}{{/server}}{{#mobile}}'mobile'{{/mobile}}]
But that example only works for two of them, not sure what changes needed for 3.
ianstormtaylor commented
Okay added list support to the prompting, so it will split on things like one, two, three
. Maybe it's possible now to use existing handlebars logic render it now?
Otherwise we might need to figure out an extension, or a way to nicely extend.
ianstormtaylor commented
fixed with prompt taking arrays now, just need to set the schema manually