mirror of
https://github.com/wassname/generator-react-webpack.git
synced 2026-09-10 12:00:17 +08:00
added flag --es6
This commit is contained in:
@@ -6,12 +6,14 @@ var generalUtils = require('../util.js');
|
||||
|
||||
var ReactWebpackGenerator = module.exports = function ReactWebpackGenerator(args, options, config) {
|
||||
yeoman.generators.Base.apply(this, arguments);
|
||||
this.option('es6');
|
||||
|
||||
this.argument('appname', { type: String, required: false });
|
||||
this.appname = this.appname || path.basename(process.cwd());
|
||||
this.appname = this._.camelize(this._.slugify(this._.humanize(this.appname)));
|
||||
this.scriptAppName = this._.capitalize(this.appname) + generalUtils.appName(this);
|
||||
|
||||
|
||||
args = ['main'];
|
||||
|
||||
if (typeof this.options.appPath === 'undefined') {
|
||||
|
||||
@@ -31,7 +31,6 @@ module.exports = {
|
||||
resolve: {
|
||||
extensions: ['', '.js', '.jsx']
|
||||
},
|
||||
|
||||
module: {
|
||||
preLoaders: [{
|
||||
test: '\\.js$',
|
||||
|
||||
Reference in New Issue
Block a user