-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
zhangxf26
authored and
zhangxf26
committed
Dec 31, 2024
1 parent
70968b7
commit 9d1c491
Showing
56 changed files
with
15,332 additions
and
13,234 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,11 @@ | ||
# http://editorconfig.org | ||
# 🎨 editorconfig.org | ||
|
||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[Makefile] | ||
indent_style = tab |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
NODE_ENV = 'production' | ||
|
||
PUBLIC_URL = '.' | ||
|
||
// 离线包目录 | ||
BUILD_PATH = 'offline-beta' | ||
|
||
// 是否使用sourcemap | ||
GENERATE_SOURCEMAP=false | ||
|
||
// 使用扩展 eslint | ||
EXTEND_ESLINT = false | ||
|
||
CI = false | ||
|
||
SKIP_PREFLIGHT_CHECK=true |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
NODE_ENV = 'production' | ||
|
||
PUBLIC_URL = '.' | ||
|
||
// 离线包目录 | ||
BUILD_PATH = 'offline-prod' | ||
|
||
// 是否使用sourcemap | ||
GENERATE_SOURCEMAP=false | ||
|
||
// 使用扩展 eslint | ||
EXTEND_ESLINT = false | ||
|
||
CI = false | ||
|
||
SKIP_PREFLIGHT_CHECK=true |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,3 @@ | ||
/build | ||
/deploy | ||
/src/setupProxy.js | ||
craco.config.js | ||
.*.js | ||
!.*.js | ||
~* | ||
es/**/* | ||
lib/**/* | ||
node_modules | ||
dist | ||
coverage | ||
**/*.d.ts | ||
build/ | ||
**/node_modules | ||
coverage/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"extends": ["react-app"], | ||
"rules": { | ||
"react-hooks/exhaustive-deps": "off" | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,23 @@ | ||
/build | ||
**/node_modules | ||
package.json | ||
.eslintignore | ||
.editorconfig | ||
**/*.png | ||
**/*.svg | ||
lib/ | ||
es/ | ||
dist/ | ||
build/ | ||
coverage/ | ||
CNAME | ||
LICENSE | ||
yarn.lock | ||
package-lock.json | ||
netlify.toml | ||
yarn-error.log | ||
*.sh | ||
*.snap | ||
.gitignore | ||
.prettierignore | ||
.gitattributes | ||
.env | ||
.env.development | ||
.env.production | ||
.DS_Store | ||
LICENSE | ||
.eslintcache | ||
**/*.svg | ||
**/*.jpg | ||
**/*.jpeg | ||
**/*.png | ||
**/*.gif | ||
**/*.ico | ||
*.lock | ||
.editorconfig | ||
.eslintignore | ||
**/*.yml | ||
*.html | ||
CHANGELOG.*.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
# [react-startup 脚手架](https://github.com/rt-zhangxuefei/react-startup) | ||
# Tips | ||
# React 项目脚手架精简版 | ||
保持 React, React Router, Redux, CRACO 版本更新 | ||
|
||
# LICENCE | ||
异步action使用redux官方推荐的thunk方式 | ||
|
||
MIT | ||
追求简洁,易用,减少各种心智负担 | ||
|
||
不追求大而全,作为一个基础的模板,在这个上面可以搭建业务项目 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,25 @@ | ||
const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer'); | ||
const AntdDayjsWebpackPlugin = require('antd-dayjs-webpack-plugin'); | ||
// const CracoLessPlugin = require('craco-less'); | ||
const CracoAntDesignPlugin = require('craco-antd'); | ||
const WebpackBar = require('webpackbar'); | ||
const ESLintPlugin = require('eslint-webpack-plugin'); | ||
const path = require('path'); | ||
|
||
// Don't open the browser during development | ||
process.env.BROWSER = 'none'; | ||
const CracoLessPlugin = require('craco-less'); | ||
|
||
module.exports = { | ||
devServer: { | ||
port: 3001 | ||
}, | ||
webpack: { | ||
plugins: [ | ||
new WebpackBar({ profile: true }), | ||
...(process.env.NODE_ENV === 'development' | ||
? [new BundleAnalyzerPlugin({ openAnalyzer: false, analyzerPort: 8888 })] | ||
: []), | ||
new ESLintPlugin(), | ||
new AntdDayjsWebpackPlugin(), | ||
], | ||
alias: { | ||
'@': require('path').resolve(__dirname, 'src') | ||
} | ||
}, | ||
plugins: [ | ||
// { | ||
// plugin: CracoLessPlugin, | ||
// options: { | ||
// lessLoaderOptions: { | ||
// lessOptions: { | ||
// javascriptEnabled: true, | ||
// }, | ||
// }, | ||
// }, | ||
// }, | ||
{ | ||
plugin: CracoAntDesignPlugin, | ||
plugin: CracoLessPlugin, | ||
options: { | ||
customizeThemeLessPath: path.join(__dirname, 'src/style/antd/customTheme.less'), | ||
}, | ||
}, | ||
], | ||
lessLoaderOptions: { | ||
lessOptions: { | ||
modifyVars: {}, | ||
javascriptEnabled: true | ||
} | ||
} | ||
} | ||
} | ||
] | ||
}; |
Oops, something went wrong.