mirror of
https://github.com/react-webpack-generators/generator-react-webpack.git
synced 2025-12-08 18:01:59 +00:00
*ADD* Base: Added esLint as new linter
This commit is contained in:
parent
c422be2253
commit
e63ddcb5f5
@ -21,6 +21,9 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"grunt": "~0.4.5",
|
||||
"eslint": "^0.21.2",
|
||||
"eslint-loader": "^0.11.2",
|
||||
"eslint-plugin-react": "^2.4.0",
|
||||
"load-grunt-tasks": "~0.6.0",
|
||||
"grunt-contrib-connect": "~0.8.0",
|
||||
"webpack": "~1.4.3",
|
||||
@ -38,8 +41,6 @@
|
||||
"karma-webpack": "~1.2.2",
|
||||
"webpack-dev-server": "~1.6.5",
|
||||
"grunt-open": "~0.2.3",
|
||||
"jshint-loader": "~0.8.0",
|
||||
"jsxhint-loader": "~0.2.0",
|
||||
"grunt-contrib-copy": "~0.5.0",
|
||||
"babel": "^4.0.0",
|
||||
"babel-loader": "^4.0.0",
|
||||
|
||||
@ -41,7 +41,7 @@ module.exports = {
|
||||
preLoaders: [{
|
||||
test: /\.(js|jsx)$/,
|
||||
exclude: /node_modules/,
|
||||
loader: 'jsxhint'
|
||||
loader: 'eslint-loader'
|
||||
}],
|
||||
loaders: [{
|
||||
test: /\.(js|jsx)$/,
|
||||
@ -69,8 +69,7 @@ module.exports = {
|
||||
},
|
||||
|
||||
plugins: [
|
||||
new webpack.HotModuleReplacementPlugin(),
|
||||
new webpack.NoErrorsPlugin()
|
||||
new webpack.HotModuleReplacementPlugin()
|
||||
]
|
||||
|
||||
};
|
||||
|
||||
@ -29,7 +29,8 @@ module.exports = {
|
||||
new webpack.optimize.DedupePlugin(),
|
||||
new webpack.optimize.UglifyJsPlugin(),
|
||||
new webpack.optimize.OccurenceOrderPlugin(),
|
||||
new webpack.optimize.AggressiveMergingPlugin()
|
||||
new webpack.optimize.AggressiveMergingPlugin(),
|
||||
new webpack.NoErrorsPlugin()
|
||||
],
|
||||
|
||||
resolve: {
|
||||
@ -45,11 +46,10 @@ module.exports = {
|
||||
|
||||
module: {
|
||||
preLoaders: [{
|
||||
test: /\.js$/,
|
||||
test: /\.(js|jsx)$/,
|
||||
exclude: /node_modules/,
|
||||
loader: 'jsxhint'
|
||||
loader: 'eslint-loader'
|
||||
}],
|
||||
|
||||
loaders: [{
|
||||
test: /\.js$/,
|
||||
exclude: /node_modules/,
|
||||
|
||||
19
templates/common/root/.eslintrc
Normal file
19
templates/common/root/.eslintrc
Normal file
@ -0,0 +1,19 @@
|
||||
{
|
||||
"plugins": [
|
||||
"react"
|
||||
],
|
||||
"ecmaFeatures": {
|
||||
"jsx": true
|
||||
},
|
||||
"env": {
|
||||
"browser": true,
|
||||
"amd": true,
|
||||
"es6": true
|
||||
},
|
||||
"rules": {
|
||||
"quotes": [ 1, "single" ],
|
||||
"no-undef": false,
|
||||
"global-strict": false,
|
||||
"no-extra-semi": 1
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user