Skip to content

Commit e1e4286

Browse files
committed
features input example @todo choose features
1 parent cd0b596 commit e1e4286

File tree

3 files changed

+35
-1
lines changed

3 files changed

+35
-1
lines changed

generators/app/utils/generate.js

-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ var generate = {
3434

3535
appfiles: function () {
3636
helpers.copy.call(this, '_package.json', 'package.json', this.prompts);
37-
console.log(this.prompts);
3837
// helpers.copy.call(this, '_bower.json', 'bower.json', this.prompts);
3938
},
4039

generators/app/utils/prompts.js

+34
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,40 @@ module.exports = {
1818
name: 'iconfont',
1919
message: 'Create iconfont from SVG?',
2020
default: true
21+
},
22+
{
23+
type: 'checkbox',
24+
name: 'features',
25+
message: 'Choose additional features',
26+
choices: [{
27+
name: 'jQuery',
28+
value: 'useJquery',
29+
checked: true
30+
}, {
31+
name: 'Image optimisation',
32+
value: 'useOptim',
33+
checked: false
34+
}, {
35+
name: 'Automatic sprites',
36+
value: 'useSprites',
37+
checked: false
38+
}, {
39+
name: 'Icomoon',
40+
value: 'useIcomoon',
41+
checked: false
42+
}, {
43+
name: 'Bootstrap',
44+
value: 'useBootstrap',
45+
checked: false
46+
}, {
47+
name: 'Modernizr',
48+
value: 'useModernizr',
49+
checked: false
50+
}, {
51+
name: 'Browserify',
52+
value: 'useBrowserify',
53+
checked: false
54+
}]
2155
}],
2256

2357
update: [{

generators/app/utils/setPrompts.js

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ module.exports = function (answers) {
88
this.prompts.spritesmith = answers.spritesmith;
99
this.prompts.jade = answers.jade;
1010
this.prompts.iconfont = answers.iconfont;
11+
this.prompts.bootstrap = answers.bootstrap;
1112
// this.prompts.cssPrefix = answers.cssPreprocessor === 'scss' ? '_' : '';
1213
this.prompts.features = {};
1314

0 commit comments

Comments
 (0)