1- const prettierConfig = require ( './.prettierrc' ) ;
2-
31module . exports = {
42 root : true ,
5- extends : [
6- 'eslint:recommended' ,
7- 'plugin:import/recommended' ,
8- 'plugin:prettier/recommended' , // Must be last
9- ] ,
10- parser : '@babel/eslint-parser' ,
3+ parser : 'babel-eslint' ,
114 parserOptions : {
125 sourceType : 'module' ,
136 ecmaVersion : 2019 ,
147 } ,
15- plugins : [ 'prettier' , 'import' ] ,
168 env : {
179 browser : true ,
18- es6 : true ,
1910 node : true ,
11+ es6 : true ,
2012 } ,
13+ plugins : [ 'prettier' , 'import' ] ,
14+ extends : [ 'eslint:recommended' , 'plugin:import/recommended' ] ,
2115 settings : {
2216 'import/ignore' : [ 'node_modules' , '.json$' ] ,
2317 } ,
2418 rules : {
19+ 'prettier/prettier' : [ 'error' ] ,
2520 camelcase : [ 'warn' ] ,
21+ 'no-useless-escape' : [ 'warn' ] ,
2622 curly : [ 'error' , 'all' ] ,
2723 'dot-notation' : [ 'error' ] ,
2824 eqeqeq : [ 'error' ] ,
@@ -37,16 +33,9 @@ module.exports = {
3733 'no-proto' : [ 'error' ] ,
3834 'no-return-assign' : [ 'error' ] ,
3935 'no-self-compare' : [ 'error' ] ,
36+ 'no-shadow' : [ 'warn' ] ,
4037 'no-shadow-restricted-names' : [ 'error' ] ,
41- 'no-shadow' : [
42- 'error' ,
43- {
44- allow : [ 'Events' , 'Fetch' , 'Lifecycle' , 'Render' , 'Router' ] ,
45- } ,
46- ] ,
47- 'no-unused-vars' : [ 'error' , { args : 'none' } ] ,
4838 'no-useless-call' : [ 'error' ] ,
49- 'no-useless-escape' : [ 'warn' ] ,
5039 'no-var' : [ 'error' ] ,
5140 'no-void' : [ 'error' ] ,
5241 'no-with' : [ 'error' ] ,
@@ -57,21 +46,18 @@ module.exports = {
5746
5847 // Import rules
5948 // Search way how integrate with `lerna`
49+ 'import/no-unresolved' : 'off' ,
6050 'import/imports-first' : [ 'error' ] ,
6151 'import/newline-after-import' : [ 'error' ] ,
6252 'import/no-duplicates' : [ 'error' ] ,
6353 'import/no-mutable-exports' : [ 'error' ] ,
64- 'import/no-named-as-default-member' : [ 'error' ] ,
6554 'import/no-named-as-default' : [ 'error' ] ,
66- 'import/no-unresolved ' : 'off' ,
55+ 'import/no-named-as-default-member ' : [ 'error' ] ,
6756 'import/order' : [ 'warn' ] ,
68-
69- // Prettier (Must be last)
70- 'prettier/prettier' : [ 'warn' , prettierConfig ] ,
7157 } ,
7258 globals : {
73- $docsify : 'writable' ,
7459 Docsify : 'writable' ,
60+ $docsify : 'writable' ,
7561 dom : 'writable' ,
7662 } ,
7763} ;
0 commit comments