File tree Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 15
15
key : ${{runner.os}}-npm-${{hashFiles('**/package-lock.json')}}
16
16
restore-keys : ${{runner.os}}-npm-
17
17
- run : npm ci
18
+ - run : npm run style:check
18
19
- run : npm test
Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ bash> npm run build
15
15
16
16
It also has a pre-commit hook configured via
17
17
[ husky] ( https://www.npmjs.com/package/husky ) that should run the build script
18
- before each commit.
18
+ before each commit. Additionally, this hook formats code and lints it, as
19
+ well.
19
20
20
21
## Releasing
21
22
Original file line number Diff line number Diff line change 8
8
"private" : true ,
9
9
"scripts" : {
10
10
"build" : " ncc build src/main.ts" ,
11
- "format" : " prettier --write src __test__" ,
11
+ "format:check" : " prettier --check src __test__" ,
12
+ "format:write" : " prettier --write src __test__" ,
12
13
"lint" : " eslint src __test__" ,
13
- "check" : " run-p --continue-on-error --aggregate-output format lint" ,
14
- "pre-commit" : " run-s check test build" ,
14
+ "style:check" : " run-p --continue-on-error --aggregate-output format:check lint" ,
15
+ "style:write" : " run-p --continue-on-error --aggregate-output format:write lint" ,
16
+ "pre-commit" : " run-s style:write test build" ,
15
17
"test" : " jest"
16
18
},
17
19
"husky" : {
You can’t perform that action at this time.
0 commit comments