mirror of
https://github.com/react-webpack-generators/generator-react-webpack.git
synced 2025-12-08 18:01:59 +00:00
Updated prompting to new yeoman-generator api (#272)
Updated prompting to new yeoman-generator api Fixes #271
This commit is contained in:
parent
9756541eca
commit
c9cfbf1e9a
@ -36,8 +36,7 @@ module.exports = generator.Base.extend({
|
|||||||
},
|
},
|
||||||
|
|
||||||
prompting: function() {
|
prompting: function() {
|
||||||
let done = this.async();
|
return this.prompt(prompts, function(props) {
|
||||||
this.prompt(prompts, function(props) {
|
|
||||||
|
|
||||||
// Make sure to get the correct app name if it is not the default
|
// Make sure to get the correct app name if it is not the default
|
||||||
if(props.appName !== utils.yeoman.getAppName()) {
|
if(props.appName !== utils.yeoman.getAppName()) {
|
||||||
@ -47,7 +46,7 @@ module.exports = generator.Base.extend({
|
|||||||
// Set needed global vars for yo
|
// Set needed global vars for yo
|
||||||
this.appName = props.appName;
|
this.appName = props.appName;
|
||||||
this.style = props.style;
|
this.style = props.style;
|
||||||
this.postcss = props.postcss
|
this.postcss = props.postcss;
|
||||||
this.generatedWithVersion = packageInfo.version.split('.').unshift();
|
this.generatedWithVersion = packageInfo.version.split('.').unshift();
|
||||||
|
|
||||||
// Set needed keys into config
|
// Set needed keys into config
|
||||||
@ -59,7 +58,6 @@ module.exports = generator.Base.extend({
|
|||||||
|
|
||||||
this.config.save();
|
this.config.save();
|
||||||
|
|
||||||
done();
|
|
||||||
}.bind(this));
|
}.bind(this));
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user