From bd65cbadfc6330e9752525a420a286d7c18fbd57 Mon Sep 17 00:00:00 2001 From: Alexander Akait <4567934+alexander-akait@users.noreply.github.com> Date: Tue, 16 Jan 2024 19:52:48 +0300 Subject: [PATCH] chore: improve tooling (#1179) --- .gitignore | 1 + lint-staged.config.js | 5 ++++- package.json | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 8f584372..f1dfdbd9 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,7 @@ logs *.log npm-debug.log* .eslintcache +.cspellcache /coverage /dist diff --git a/lint-staged.config.js b/lint-staged.config.js index 372e7ffc..30108433 100644 --- a/lint-staged.config.js +++ b/lint-staged.config.js @@ -1,4 +1,7 @@ module.exports = { - "*": ["prettier --write --ignore-unknown", "cspell --no-must-find-files"], + "*": [ + "prettier --cache --write --ignore-unknown", + "cspell --cache --no-must-find-files", + ], "*.js": ["eslint --cache --fix"], }; diff --git a/package.json b/package.json index 8bf4fcef..3f63b075 100644 --- a/package.json +++ b/package.json @@ -22,14 +22,14 @@ "build": "cross-env NODE_ENV=production babel src -d dist --copy-files", "commitlint": "commitlint --from=master", "security": "npm audit --production", - "lint:prettier": "prettier --list-different .", + "lint:prettier": "prettier --cache --list-different .", "lint:js": "eslint --cache .", + "lint:spelling": "cspell --cache --no-must-find-files --quiet \"**/*.*\"", "lint": "npm-run-all -l -p \"lint:**\"", "test:only": "cross-env NODE_ENV=test jest", "fix:js": "npm run lint:js -- --fix", "fix:prettier": "npm run lint:prettier -- --write", "fix": "npm-run-all -l fix:js fix:prettier", - "lint:spelling": "cspell \"**/*.*\"", "test:watch": "npm run test:only -- --watch", "test:manual": "npm run build && webpack-dev-server test/manual/src/index.js --open --config test/manual/webpack.config.js", "test:coverage": "npm run test:only -- --collectCoverageFrom=\"src/**/*.js\" --coverage",