From 6211b4b05b3e0b4719af7ff9636cc4a8c93704ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E7=88=B1=E5=90=83=E7=99=BD=E8=90=9D?= =?UTF-8?q?=E5=8D=9C?= Date: Thu, 3 Apr 2025 11:02:04 +0800 Subject: [PATCH] refactor: Update build tools (#53390) * chore: update config * chore: update deps * chore: bump deps * chore: update deps --- package.json | 6 +++--- tsconfig.json | 2 +- webpack.config.js | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 4bb8a0744c..f4504b9e37 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,8 @@ "clean": "antd-tools run clean && rimraf es lib coverage locale dist report.html artifacts.zip oss-artifacts.zip", "clean:lockfiles": "rimraf package-lock.json yarn.lock", "precompile": "npm run prestart", - "compile": "npm run clean && antd-tools run compile", + "compile": "npm run compileOnly", + "compileOnly": "npm run clean && antd-tools run compile", "predeploy": "antd-tools run clean && npm run site && cp CNAME _site && npm run test:site", "deploy": "gh-pages -d _site -b gh-pages -f", "deploy:china-mirror": "git checkout gh-pages && git pull origin gh-pages && git push git@gitee.com:ant-design/ant-design.git gh-pages -f", @@ -61,7 +62,6 @@ "prelint": "dumi setup", "lint": "npm run version && npm run tsc && npm run lint:script && npm run lint:biome && npm run lint:md && npm run lint:changelog", "lint:changelog": "tsx scripts/generate-component-changelog.ts", - "lint:deps": "antd-tools run deps-lint", "lint:md": "remark . -f -q", "lint:script": "eslint . --cache", "lint:biome": "biome lint", @@ -159,7 +159,7 @@ "devDependencies": { "@ant-design/compatible": "^5.1.3", "@ant-design/happy-work-theme": "^1.0.0", - "@ant-design/tools": "^18.0.3", + "@ant-design/tools": "^19.0.1", "@ant-design/v5-patch-for-react-19": "^1.0.2", "@antfu/eslint-config": "^4.0.0", "@antv/g6": "^4.8.24", diff --git a/tsconfig.json b/tsconfig.json index 005213bbea..9ea8f64e29 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,6 +1,6 @@ { "compilerOptions": { - "target": "es6", + "target": "es2020", "jsx": "react", "jsxFactory": "React.createElement", "jsxFragmentFactory": "React.Fragment", diff --git a/webpack.config.js b/webpack.config.js index eb665de5f1..c77fa99630 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,6 +1,6 @@ /* eslint no-param-reassign: 0 */ // This config is for building dist files -const getWebpackConfig = require('@ant-design/tools/lib/getWebpackConfig'); +const { getWebpackConfig } = require('@ant-design/tools'); const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer'); const { codecovWebpackPlugin } = require('@codecov/webpack-plugin'); const CircularDependencyPlugin = require('circular-dependency-plugin');