Browse Source

fix: update simple script to match current project state (#11718)

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
pull/11720/head
Alex Zhu 5 months ago
committed by GitHub
parent
commit
21b6328167
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 18
      scripts/simple.js

18
scripts/simple.js

@ -4,8 +4,8 @@
*
* 此操作不可逆,会删除以下内容:
* - 页面目录:dashboard, form, list/basic-list, list/card-list, list/search, profile, result, exception, account, user/register, user/register-result
* - Mock 文件:analysis.mock.ts, workplace.mock.ts
* - 替换路由配置为简单版
* - 移除不再需要的依赖:@ant-design/plots, d3, topojson-client
*/
const fs = require('node:fs');
@ -27,17 +27,17 @@ const pageDirsToDelete = [
];
// 需要删除的 mock 文件
const mockFilesToDelete = ['mock/analysis.mock.ts', 'mock/workplace.mock.ts'];
const mockFilesToDelete = [];
// 需要从 package.json 移除的依赖
const depsToRemove = [
'@ant-design/plots',
'@antv/l7-react',
'@antv/l7',
'numeral',
];
const depsToRemove = ['@ant-design/plots', 'd3', 'topojson-client'];
const devDepsToRemove = ['@types/numeral'];
const devDepsToRemove = [
'@types/d3',
'@types/topojson-client',
'@types/topojson-specification',
'geojson',
];
// 递归删除目录
function deleteDir(dirPath) {

Loading…
Cancel
Save