"commitizen": "^4.2.4",
"cz-customizable": "^6.3.0",
https://github.com/commitizen/cz-cli
.cz-config.js
.czrc
结合 JIRA,自动生产消息
husky
https://github.com/typicode/husky "husky": "4.3.8",
package.json
"husky": {
"hooks": {
"pre-commit": "lint-staged",
"commit-msg": "commitlint --config commitlint.config.js -E HUSKY_GIT_PARAMS"
}
},
"@commitlint/cli": "^16.1.0",
"@commitlint/config-conventional": "^16.0.0",
commitlint.config.js
package.json
"commit-msg": "commitlint --config commitlint.config.js -E HUSKY_GIT_PARAMS"
"lint-staged": "^12.3.3",
package.json
"lint-staged": {
"*.{ts,tsx,js}": [
"eslint"
],
"*.{ts,tsx,js,json,html,yml,css,less,scss,md}": [
"prettier --write"
]
}
https://github.com/okonet/lint-staged#readme
"tsconfig-paths-webpack-plugin": "^3.5.2"
"@typescript-eslint/eslint-plugin": "^5.10.2",
"@typescript-eslint/parser": "^5.10.2",
"typescript": "^4.5.5",
解析 ts 和 js 相关依赖
"@babel/cli": "^7.17.0",
"@babel/core": "^7.17.0",
"@babel/plugin-transform-runtime": "^7.17.0",
"@babel/preset-env": "^7.16.11",
"@babel/preset-react": "^7.16.7",
"@babel/preset-typescript": "^7.16.7",
"babel-loader": "^8.2.3",
"@babel/runtime-corejs3": "^7.17.2",
解析 css 相关依赖
"css-loader": "^6.6.0",
"css-minimizer-webpack-plugin": "^3.4.1",
"mini-css-extract-plugin": "^2.5.3",
"postcss-flexbugs-fixes": "^5.0.2",
"postcss-loader": "^6.2.1",
"postcss-normalize": "^10.0.1",
"postcss-preset-env": "^7.3.2",
"style-loader": "^3.3.1",
开启 webpack 多线程 相关依赖
"thread-loader": "^3.0.4",
每次打包前清空目标文件夹
从 js 中分离 css
在页面上显示编译错误
复制资源文件到目标文件夹
在编译过程中根据 eslint 检查代码
自动成功 HTML 并引入资源文件
因为从 js 分离出去后,css 不会压缩,需要插件来压缩资源
压缩 js
构建包大小分析
构建进度展示
- es-build