@devflow-tools/plugin-taro 0.8.10 → 0.9.0
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 +27 -5
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @devflow-tools/plugin-taro
|
|
2
2
|
|
|
3
|
-
Taro
|
|
3
|
+
Taro 跨端专家插件 — 多端适配、小程序调试、性能优化、兼容方案。
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
@@ -8,11 +8,33 @@ Taro cross-platform expert plugin for DevFlow — multi-platform adaptation, min
|
|
|
8
8
|
npm install @devflow-tools/plugin-taro
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
##
|
|
11
|
+
## MCP Tools
|
|
12
12
|
|
|
13
|
-
|
|
|
14
|
-
|
|
15
|
-
| `
|
|
13
|
+
| Tool | 说明 | 关键参数 |
|
|
14
|
+
|------|------|---------|
|
|
15
|
+
| `taro_new_page` | 新建 Taro 页面(跨端兼容 + 路由注册 + 分包配置) | `projectRoot` |
|
|
16
|
+
|
|
17
|
+
## Knowledge Sources
|
|
18
|
+
|
|
19
|
+
| 来源 | URL | SPA |
|
|
20
|
+
|------|-----|-----|
|
|
21
|
+
| Taro 官方文档 | https://docs.taro.zone/docs | Yes |
|
|
22
|
+
|
|
23
|
+
## Memory
|
|
24
|
+
|
|
25
|
+
插件自动注入以下最佳实践:
|
|
26
|
+
- `Taro.getSystemInfoSync()` 获取平台信息
|
|
27
|
+
- 条件编译:`process.env.TARO_ENV` 区分 h5/weapp/alipay
|
|
28
|
+
- 小程序分包策略:主包 < 2MB 限制
|
|
29
|
+
- 样式单位统一使用 `px`(Taro 自动转换)
|
|
30
|
+
- 使用 `@tarojs/plugin-html` 支持 HTML 标签
|
|
31
|
+
|
|
32
|
+
## Usage
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
# 在 Claude Code 中使用
|
|
36
|
+
/devflow:taro 创建订单列表页面
|
|
37
|
+
```
|
|
16
38
|
|
|
17
39
|
## License
|
|
18
40
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devflow-tools/plugin-taro",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -26,5 +26,5 @@
|
|
|
26
26
|
"files": [
|
|
27
27
|
"dist"
|
|
28
28
|
],
|
|
29
|
-
"gitHead": "
|
|
29
|
+
"gitHead": "7872bccedbacd09cc92b983f30b3702db6878125"
|
|
30
30
|
}
|