File tree Expand file tree Collapse file tree 4 files changed +473
-8
lines changed Expand file tree Collapse file tree 4 files changed +473
-8
lines changed Original file line number Diff line number Diff line change 1
1
module . exports = {
2
- extends : [ "airbnb-base" , "prettier" ]
3
- } ;
2
+ extends : [ 'airbnb-base' , 'prettier' ] ,
3
+ plugins : [ 'prettier' ] ,
4
+ rules : {
5
+ 'prettier/prettier' : 2 ,
6
+ } ,
7
+ }
Original file line number Diff line number Diff line change 7
7
- node --version
8
8
- yarn --version
9
9
- yarn run test
10
+ - yarn run lint
10
11
notifications :
11
12
email :
12
13
on_failure : change
Original file line number Diff line number Diff line change 7
7
"build" : " babel src --ignore test.js --out-dir dist" ,
8
8
"test" : " jest" ,
9
9
"test:watch" : " jest --watch" ,
10
- "prepublish" : " npm run build"
10
+ "lint" : " eslint src" ,
11
+ "prepublish" : " npm run build" ,
12
+ "precommit" : " lint-staged" ,
13
+ "lint-staged" : " lint-staged"
11
14
},
12
15
"files" : [
13
16
" dist" ,
37
40
"eslint-config-airbnb-base" : " ^10.0.1" ,
38
41
"eslint-config-prettier" : " ^2.9.0" ,
39
42
"eslint-plugin-import" : " ^2.2.0" ,
43
+ "eslint-plugin-prettier" : " ^2.6.0" ,
40
44
"jest" : " ^17.0.0" ,
45
+ "lint-staged" : " ^6.1.0" ,
41
46
"prettier" : " ^1.10.2"
42
47
},
43
48
"dependencies" : {
44
49
"css-color-keywords" : " ^1.0.0" ,
45
50
"fbjs" : " ^0.8.5" ,
46
51
"postcss-value-parser" : " ^3.3.0"
52
+ },
53
+ "lint-staged" : {
54
+ "*.js" : [
55
+ " eslint --fix" ,
56
+ " git add"
57
+ ]
47
58
}
48
59
}
You can’t perform that action at this time.
0 commit comments