Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 46eb5ef

Browse files
committed
perf: update packages
1 parent 5f1167c commit 46eb5ef

File tree

5 files changed

+48
-43
lines changed

5 files changed

+48
-43
lines changed

‎.gitignore‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ build
4040
yarn.lock
4141
.vscode/*
4242
dll
43+
pnpm-lock.yaml
4344

4445
# Optional npm cache directory
4546
.npm

‎package.json‎

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -24,63 +24,63 @@
2424
},
2525
"dependencies": {
2626
"@rematch/core": "^2.2.0",
27-
"antd": "^4.20.1",
27+
"antd": "^4.21.2",
2828
"axios": "^0.27.2",
29-
"core-js": "^3.22.3",
29+
"core-js": "^3.23.1",
3030
"lodash": "^4.17.21",
31-
"react": "^18.1.0",
32-
"react-dom": "^18.1.0",
31+
"react": "^18.2.0",
32+
"react-dom": "^18.2.0",
3333
"react-loadable": "^5.5.0",
34-
"react-redux": "^8.0.1",
34+
"react-redux": "^8.0.2",
3535
"react-router-dom": "^6.3.0",
3636
"redux": "^4.2.0"
3737
},
3838
"devDependencies": {
39-
"@babel/core": "^7.17.9",
40-
"@babel/eslint-parser": "^7.17.0",
41-
"@babel/plugin-proposal-class-properties": "^7.16.7",
42-
"@babel/plugin-proposal-decorators": "^7.17.9",
43-
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.16.7",
44-
"@babel/plugin-proposal-object-rest-spread": "^7.17.3",
45-
"@babel/plugin-proposal-optional-chaining": "^7.16.7",
39+
"@babel/core": "^7.18.5",
40+
"@babel/eslint-parser": "^7.18.2",
41+
"@babel/plugin-proposal-class-properties": "^7.17.12",
42+
"@babel/plugin-proposal-decorators": "^7.18.2",
43+
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.17.12",
44+
"@babel/plugin-proposal-object-rest-spread": "^7.18.0",
45+
"@babel/plugin-proposal-optional-chaining": "^7.17.12",
4646
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
47-
"@babel/plugin-transform-runtime": "^7.17.0",
48-
"@babel/preset-env": "^7.16.11",
49-
"@babel/preset-react": "^7.16.7",
50-
"@babel/runtime": "^7.17.9",
47+
"@babel/plugin-transform-runtime": "^7.18.5",
48+
"@babel/preset-env": "^7.18.2",
49+
"@babel/preset-react": "^7.17.12",
50+
"@babel/runtime": "^7.18.3",
5151
"antd-dayjs-webpack-plugin": "^1.0.6",
52-
"autoprefixer": "^10.4.5",
52+
"autoprefixer": "^10.4.7",
5353
"babel-loader": "^8.2.5",
5454
"babel-plugin-import": "^1.13.5",
5555
"clean-webpack-plugin": "^4.0.0",
56-
"copy-webpack-plugin": "^10.2.4",
56+
"copy-webpack-plugin": "^11.0.0",
5757
"css-loader": "^6.7.1",
58-
"css-minimizer-webpack-plugin": "^3.4.1",
59-
"dayjs": "^1.11.1",
60-
"eslint": "^8.14.0",
58+
"css-minimizer-webpack-plugin": "^4.0.0",
59+
"dayjs": "^1.11.3",
60+
"eslint": "^8.17.0",
6161
"eslint-plugin-prettier": "^4.0.0",
62-
"eslint-plugin-react": "^7.29.4",
63-
"eslint-plugin-react-hooks": "^4.5.0",
62+
"eslint-plugin-react": "^7.30.0",
63+
"eslint-plugin-react-hooks": "^4.6.0",
6464
"eslint-webpack-plugin": "^3.1.1",
65-
"express": "^4.18.0",
65+
"express": "^4.18.1",
6666
"favicons": "^6.2.2",
6767
"favicons-webpack-plugin": "^5.0.2",
6868
"happypack": "^5.0.1",
6969
"html-webpack-plugin": "^5.5.0",
70-
"less": "^4.1.2",
71-
"less-loader": "^10.2.0",
72-
"mini-css-extract-plugin": "^2.6.0",
70+
"less": "^4.1.3",
71+
"less-loader": "^11.0.0",
72+
"mini-css-extract-plugin": "^2.6.1",
7373
"mockjs": "^1.1.0",
74-
"postcss": "^8.4.12",
75-
"postcss-loader": "^6.2.1",
76-
"prettier": "^2.6.2",
74+
"postcss": "^8.4.14",
75+
"postcss-loader": "^7.0.0",
76+
"prettier": "^2.7.0",
7777
"style-loader": "^3.3.1",
7878
"sw-precache-webpack-plugin": "^1.0.0",
79-
"terser-webpack-plugin": "^5.3.1",
80-
"webpack": "^5.72.0",
79+
"terser-webpack-plugin": "^5.3.3",
80+
"webpack": "^5.73.0",
8181
"webpack-bundle-analyzer": "^4.5.0",
82-
"webpack-cli": "^4.9.2",
83-
"webpack-dev-middleware": "^5.3.1",
82+
"webpack-cli": "^4.10.0",
83+
"webpack-dev-middleware": "^5.3.3",
8484
"webpack-hot-middleware": "^2.25.1",
8585
"webpackbar": "^5.0.2",
8686
"workbox-webpack-plugin": "^6.5.3",

‎src/component/menu/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export default function Menu() {
2020
</Link>
2121
|
2222
<span
23-
class="link"
23+
className="link"
2424
onClick={() => goToTest()}
2525
to={{
2626
pathname: "/test",

‎src/container/test/index.js‎

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,9 @@ export default function TestPageContainer() {
4949
};
5050

5151
// 仅组件加载完毕时触发一次
52-
useEffect(async() => {
52+
useEffect(() => {
5353
// console.log("所有页面默认拥有的3个对象:", location, match, history);
54+
5455
const set = new Set([1, 2, 3]);
5556
const map = new Map();
5657
console.log("Set 和 Map 测试:", set, map);
@@ -60,11 +61,14 @@ export default function TestPageContainer() {
6061
console.log("obj的扩展运算符测试:", b);
6162

6263
// 获取用户信息测试
63-
const userInfo = await dispatch({
64-
type: "app/getUserinfo",
65-
payload: { id: 1 },
66-
});
67-
console.log("获取到userInfo:", userInfo);
64+
async function getUserinfo() {
65+
const userInfo = await dispatch({
66+
type: "app/getUserinfo",
67+
payload: { id: 1 },
68+
});
69+
console.log("获取到userInfo:", userInfo);
70+
}
71+
getUserinfo();
6872
}, []);
6973

7074
// 表单提交且验证通过时触发

‎src/index.js‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
// import "regenerator-runtime/runtime";
44

55
import React from "react";
6-
import ReactDOM from "react-dom";
6+
import ReactDOM from "react-dom/client";
77
import Root from "./root";
88

99
/** 公共样式 **/
1010
import "./styles/css.css";
1111
import "./styles/less.less";
1212

13-
ReactDOM.render(<Root/>,document.getElementById("app-root"));
13+
ReactDOM.createRoot(document.getElementById("app-root")).render(<Root/>);
1414

1515
if (module.hot) {
1616
module.hot.accept();

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /