@ant-design/cli 6.3.5 → 6.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -0
- package/README.zh-CN.md +15 -0
- package/data/v3.26.20.json.gz +0 -0
- package/data/v3.json.gz +0 -0
- package/data/v6.3.6.json.gz +0 -0
- package/data/v6.json.gz +0 -0
- package/data/versions.json +4 -1
- package/dist/index.js +741 -208
- package/package.json +8 -8
- package/skills/antd/SKILL.md +8 -20
package/README.md
CHANGED
|
@@ -104,12 +104,16 @@ This exposes 7 tools (`antd_list`, `antd_info`, `antd_doc`, `antd_demo`, `antd_t
|
|
|
104
104
|
## 🚀 Quick Start
|
|
105
105
|
|
|
106
106
|
```bash
|
|
107
|
+
antd list # All components with versions
|
|
107
108
|
antd info Button # Component props, types, defaults
|
|
109
|
+
antd doc Button # Full markdown documentation
|
|
108
110
|
antd demo Select basic # Runnable demo source code
|
|
109
111
|
antd token DatePicker # Design Token values (v5+)
|
|
110
112
|
antd semantic Table # classNames / styles structure
|
|
111
113
|
antd changelog 4.24.0 5.0.0 Select # API diff across versions
|
|
112
114
|
antd doctor # Diagnose project issues
|
|
115
|
+
antd env # Collect env info for bug reports
|
|
116
|
+
antd usage ./src # Analyze antd imports in project
|
|
113
117
|
antd lint ./src # Check deprecated APIs & best practices
|
|
114
118
|
antd migrate 4 5 --apply ./src # Agent-ready migration prompt
|
|
115
119
|
```
|
|
@@ -338,8 +342,11 @@ Four rule categories: `deprecated`, `a11y`, `performance`, `best-practice`. Depr
|
|
|
338
342
|
antd lint ./src
|
|
339
343
|
antd lint ./src --only deprecated
|
|
340
344
|
antd lint ./src --only a11y
|
|
345
|
+
antd lint ./src --only deprecated --format json --antd-alias @shared-components
|
|
341
346
|
```
|
|
342
347
|
|
|
348
|
+
Use `--antd-alias <source>` to treat additional package names as aliases of `antd`. Repeat the flag for multiple wrapper packages; `antd` remains enabled by default.
|
|
349
|
+
|
|
343
350
|
### `antd migrate <from> <to>`
|
|
344
351
|
|
|
345
352
|
v4→v5 covers 25+ migration steps; v5→v6 covers 30+. Each step includes component name, breaking flag, search pattern, and before/after code.
|
|
@@ -394,6 +401,14 @@ antd bug-cli --title "..." --submit
|
|
|
394
401
|
|
|
395
402
|
**Version auto-detection**: `--version` flag → `node_modules/antd` → `package.json` dependencies → fallback `5.24.0`
|
|
396
403
|
|
|
404
|
+
### Environment Variables
|
|
405
|
+
|
|
406
|
+
| Variable | Description |
|
|
407
|
+
|---|---|
|
|
408
|
+
| `ANTD_NO_AUTO_REPORT=1` | Disable bug-reporting suggestions from AI agents (see [#82](https://github.com/ant-design/ant-design-cli/issues/82)) |
|
|
409
|
+
| `NO_UPDATE_CHECK=1` | Skip the silent version update check |
|
|
410
|
+
| `CI=1` | Skip the silent version update check (same as `NO_UPDATE_CHECK=1`) |
|
|
411
|
+
|
|
397
412
|
<br>
|
|
398
413
|
|
|
399
414
|
## 📄 License
|
package/README.zh-CN.md
CHANGED
|
@@ -104,12 +104,16 @@ Agent 会自动完成 `npm install`、`npx skills add`,并开始使用 CLI。
|
|
|
104
104
|
## 🚀 快速开始
|
|
105
105
|
|
|
106
106
|
```bash
|
|
107
|
+
antd list # 所有组件及版本信息
|
|
107
108
|
antd info Button # 组件 Props、类型、默认值
|
|
109
|
+
antd doc Button # 完整 Markdown 文档
|
|
108
110
|
antd demo Select basic # 可运行的 Demo 源码
|
|
109
111
|
antd token DatePicker # Design Token 值(v5+)
|
|
110
112
|
antd semantic Table # classNames / styles 结构
|
|
111
113
|
antd changelog 4.24.0 5.0.0 Select # 跨版本 API 差异对比
|
|
112
114
|
antd doctor # 诊断项目配置问题
|
|
115
|
+
antd env # 收集环境信息用于 Bug 报告
|
|
116
|
+
antd usage ./src # 分析项目中的 antd 导入
|
|
113
117
|
antd lint ./src # 检查废弃 API 和最佳实践
|
|
114
118
|
antd migrate 4 5 --apply ./src # 生成 Agent 迁移提示
|
|
115
119
|
```
|
|
@@ -338,8 +342,11 @@ antd usage -f Button # 过滤特定组件
|
|
|
338
342
|
antd lint ./src
|
|
339
343
|
antd lint ./src --only deprecated
|
|
340
344
|
antd lint ./src --only a11y
|
|
345
|
+
antd lint ./src --only deprecated --format json --antd-alias @shared-components
|
|
341
346
|
```
|
|
342
347
|
|
|
348
|
+
使用 `--antd-alias <source>` 可以把额外包名视为 `antd` 的别名;可重复传入多个包装包名,且默认仍会匹配 `antd`。
|
|
349
|
+
|
|
343
350
|
### `antd migrate <from> <to>`
|
|
344
351
|
|
|
345
352
|
v4→v5 包含 25+ 迁移步骤,v5→v6 包含 30+。每个步骤包含组件名、破坏性标记、搜索正则和前后代码对比。
|
|
@@ -394,6 +401,14 @@ antd bug-cli --title "..." --submit
|
|
|
394
401
|
|
|
395
402
|
**版本自动检测**:`--version` 参数 → `node_modules/antd` → `package.json` 依赖声明 → 回退 `5.24.0`
|
|
396
403
|
|
|
404
|
+
### 环境变量
|
|
405
|
+
|
|
406
|
+
| 变量 | 说明 |
|
|
407
|
+
|---|---|
|
|
408
|
+
| `ANTD_NO_AUTO_REPORT=1` | 禁用 AI Agent 的 Bug 上报建议(详见 [#82](https://github.com/ant-design/ant-design-cli/issues/82)) |
|
|
409
|
+
| `NO_UPDATE_CHECK=1` | 跳过静默版本更新检查 |
|
|
410
|
+
| `CI=1` | 跳过静默版本更新检查(同 `NO_UPDATE_CHECK=1`) |
|
|
411
|
+
|
|
397
412
|
<br>
|
|
398
413
|
|
|
399
414
|
## 📄 开源协议
|
|
Binary file
|
package/data/v3.json.gz
ADDED
|
Binary file
|
|
Binary file
|
package/data/v6.json.gz
CHANGED
|
Binary file
|
package/data/versions.json
CHANGED