chore: migrate to webpack@5 (#45926)

* chore: migrate to webpack@5

* chore: bump

* chore: remove openssl-legacy-provider

* chore: update

* chore: update

* chore: ls webpack

* chore: update  webpack

* chore: update ci

* chore: bump version

* chore: bump

* chore: use forked duplicate check

* chore: bump

* chore: code clean

* chore: update ci

* Revert "chore: update ci"

This reverts commit 0307146dc8.

* chore: update ci
This commit is contained in:
MadCcc 2023-11-23 20:15:12 +08:00 committed by GitHub
parent 6b18c85aa3
commit 5b5087dcee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 10 additions and 11 deletions

View File

@ -8,8 +8,6 @@ jobs:
test-argos-ci:
docker:
- image: cimg/node:21.2-browsers
environment:
NODE_OPTIONS: --openssl-legacy-provider
steps:
- checkout
- run:

View File

@ -74,7 +74,7 @@ jobs:
run: npm run site
env:
SITE_ENV: development
NODE_OPTIONS: "--max_old_space_size=4096 --openssl-legacy-provider"
NODE_OPTIONS: "--max_old_space_size=4096"
- name: upload site artifact
uses: actions/upload-artifact@v3

View File

@ -70,13 +70,13 @@ jobs:
- name: build site
run: npm run predeploy
env:
NODE_OPTIONS: "--max_old_space_size=4096 --openssl-legacy-provider"
NODE_OPTIONS: "--max_old_space_size=4096"
- name: build dist and bundle analyzer report
run: npm run dist
env:
ANALYZER: 1
NODE_OPTIONS: "--max_old_space_size=4096 --openssl-legacy-provider"
NODE_OPTIONS: "--max_old_space_size=4096"
- name: Get version
id: publish-version

View File

@ -131,7 +131,7 @@ jobs:
- name: dist
run: npm run dist
env:
NODE_OPTIONS: "--max_old_space_size=4096 --openssl-legacy-provider"
NODE_OPTIONS: "--max_old_space_size=4096"
CI: 1
needs: setup

View File

@ -164,7 +164,7 @@
"devDependencies": {
"@ant-design/compatible": "^5.1.2",
"@ant-design/happy-work-theme": "^1.0.0",
"@ant-design/tools": "^17.3.2",
"@ant-design/tools": "^18.0.0",
"@antv/g6": "^4.8.13",
"@argos-ci/core": "^1.0.0",
"@babel/eslint-plugin": "^7.19.1",
@ -177,6 +177,7 @@
"@emotion/react": "^11.10.4",
"@emotion/server": "^11.4.0",
"@ianvs/prettier-plugin-sort-imports": "^4.1.0",
"@madccc/duplicate-package-checker-webpack-plugin": "^1.0.0",
"@qixian.cs/github-contributors-list": "^1.1.0",
"@size-limit/file": "^11.0.0",
"@stackblitz/sdk": "^1.3.0",
@ -222,7 +223,6 @@
"dekko": "^0.2.1",
"dumi": "^2.3.0-alpha.9",
"dumi-plugin-color-chunk": "^1.0.2",
"duplicate-package-checker-webpack-plugin": "^3.0.0",
"esbuild-loader": "^4.0.0",
"eslint": "^8.40.0",
"eslint-config-airbnb": "^19.0.0",
@ -311,6 +311,7 @@
"typescript": "~5.2.2",
"vanilla-jsoneditor": "^0.18.0",
"vanilla-tilt": "^1.8.1",
"webpack": "^5.89.0",
"webpack-bundle-analyzer": "^4.1.0",
"xhr-mock": "^2.4.1"
},
@ -330,11 +331,11 @@
"size-limit": [
{
"path": "./dist/antd.min.js",
"limit": "402 KiB"
"limit": "325 KiB"
},
{
"path": "./dist/antd-with-locales.min.js",
"limit": "461 KiB"
"limit": "371 KiB"
}
],
"title": "Ant Design",

View File

@ -4,7 +4,7 @@ const getWebpackConfig = require('@ant-design/tools/lib/getWebpackConfig');
const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer');
const { EsbuildPlugin } = require('esbuild-loader');
const CircularDependencyPlugin = require('circular-dependency-plugin');
const DuplicatePackageCheckerPlugin = require('duplicate-package-checker-webpack-plugin');
const DuplicatePackageCheckerPlugin = require('@madccc/duplicate-package-checker-webpack-plugin');
const path = require('path');
function addLocales(webpackConfig) {