From ede23675fecdfc8540d44e2c2ef40913a8ae4662 Mon Sep 17 00:00:00 2001 From: neverland Date: Thu, 1 Nov 2018 20:25:27 +0800 Subject: [PATCH] [improvement] optimize component registration (#846) --- example/app.json | 46 +++++++++++++++++++++++++++ example/pages/action-sheet/index.json | 7 +--- example/pages/area/index.json | 6 +--- example/pages/badge/index.json | 7 +--- example/pages/button/index.json | 7 +--- example/pages/card/index.json | 8 +---- example/pages/cell/index.json | 9 +----- example/pages/checkbox/index.json | 9 +----- example/pages/col/index.json | 7 +--- example/pages/dashboard/index.json | 7 +--- example/pages/dialog/index.json | 8 +---- example/pages/field/index.json | 8 +---- example/pages/goods-action/index.json | 10 +----- example/pages/icon/index.json | 7 +--- example/pages/loading/index.json | 6 +--- example/pages/nav-bar/index.json | 7 +--- example/pages/notice-bar/index.json | 6 +--- example/pages/notify/index.json | 7 +--- example/pages/panel/index.json | 7 +--- example/pages/popup/index.json | 7 +--- example/pages/progress/index.json | 6 +--- example/pages/radio/index.json | 9 +----- example/pages/search/index.json | 6 +--- example/pages/slider/index.json | 6 +--- example/pages/stepper/index.json | 7 +--- example/pages/steps/index.json | 7 +--- example/pages/submit-bar/index.json | 8 +---- example/pages/swipe-cell/index.json | 9 +----- example/pages/switch-cell/index.json | 6 +--- example/pages/switch/index.json | 7 +--- example/pages/tab/index.json | 7 +--- example/pages/tabbar/index.json | 7 +--- example/pages/tag/index.json | 6 +--- example/pages/toast/index.json | 7 +--- example/pages/transition/index.json | 7 +--- example/pages/tree-select/index.json | 6 +--- packages/action-sheet/README.md | 2 +- packages/area/README.md | 2 +- packages/badge/README.md | 2 +- packages/card/README.md | 2 +- packages/cell/README.md | 2 +- packages/checkbox/README.md | 2 +- packages/col/README.md | 2 +- packages/dialog/README.md | 2 +- packages/field/README.md | 2 +- packages/goods-action/README.md | 2 +- packages/icon/README.md | 2 +- packages/loading/README.md | 2 +- packages/nav-bar/README.md | 2 +- packages/notice-bar/README.md | 2 +- packages/notify/README.md | 2 +- packages/panel/README.md | 2 +- packages/popup/README.md | 2 +- packages/progress/README.md | 2 +- packages/radio/README.md | 2 +- packages/search/README.md | 2 +- packages/slider/README.md | 2 +- packages/stepper/README.md | 2 +- packages/steps/README.md | 2 +- packages/submit-bar/README.md | 2 +- packages/swipe-cell/README.md | 2 +- packages/switch-cell/README.md | 2 +- packages/switch/README.md | 2 +- packages/tab/README.md | 2 +- packages/tabbar/README.md | 2 +- packages/tag/README.md | 2 +- packages/toast/README.md | 2 +- packages/transition/README.md | 2 +- packages/tree-select/README.md | 2 +- 69 files changed, 114 insertions(+), 249 deletions(-) diff --git a/example/app.json b/example/app.json index b74be0dc..2d48a667 100644 --- a/example/app.json +++ b/example/app.json @@ -42,5 +42,51 @@ "navigationBarTextStyle": "black", "backgroundTextStyle": "dark", "backgroundColor": "#f8f8f8" + }, + "usingComponents": { + "demo-block": "../../components/demo-block/index", + "van-action-sheet": "../../dist/action-sheet/index", + "van-area": "../../dist/area/index", + "van-badge": "../../dist/badge/index", + "van-badge-group": "../../dist/badge-group/index", + "van-button": "../../dist/button/index", + "van-card": "../../dist/card/index", + "van-cell": "../../dist/cell/index", + "van-cell-group": "../../dist/cell-group/index", + "van-checkbox": "../../dist/checkbox/index", + "van-checkbox-group": "../../dist/checkbox-group/index", + "van-col": "../../dist/col/index", + "van-dialog": "../../dist/dialog/index", + "van-field": "../../dist/field/index", + "van-goods-action": "../../dist/goods-action/index", + "van-goods-action-icon": "../../dist/goods-action-icon/index", + "van-goods-action-button": "../../dist/goods-action-button/index", + "van-icon": "../../dist/icon/index", + "van-loading": "../../dist/loading/index", + "van-nav-bar": "../../dist/nav-bar/index", + "van-notice-bar": "../../dist/notice-bar/index", + "van-notify": "../../dist/notify/index", + "van-panel": "../../dist/panel/index", + "van-popup": "../../dist/popup/index", + "van-progress": "../../dist/progress/index", + "van-radio": "../../dist/radio/index", + "van-radio-group": "../../dist/radio-group/index", + "van-row": "../../dist/row/index", + "van-search": "../../dist/search/index", + "van-slider": "../../dist/slider/index", + "van-stepper": "../../dist/stepper/index", + "van-steps": "../../dist/steps/index", + "van-submit-bar": "../../dist/submit-bar/index", + "van-swipe-cell": "../../dist/swipe-cell/index", + "van-switch": "../../dist/switch/index", + "van-switch-cell": "../../dist/switch-cell/index", + "van-tab": "../../dist/tab/index", + "van-tabs": "../../dist/tabs/index", + "van-tabbar": "../../dist/tabbar/index", + "van-tabbar-item": "../../dist/tabbar-item/index", + "van-tag": "../../dist/tag/index", + "van-toast": "../../dist/toast/index", + "van-transition": "../../dist/transition/index", + "van-tree-select": "../../dist/tree-select/index" } } diff --git a/example/pages/action-sheet/index.json b/example/pages/action-sheet/index.json index 2fe4bc25..acb393b9 100644 --- a/example/pages/action-sheet/index.json +++ b/example/pages/action-sheet/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "ActionSheet 上拉菜单", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-action-sheet": "../../dist/action-sheet/index", - "van-button": "../../dist/button/index" - } + "navigationBarTitleText": "ActionSheet 上拉菜单" } diff --git a/example/pages/area/index.json b/example/pages/area/index.json index cc501a91..aa7d1ada 100644 --- a/example/pages/area/index.json +++ b/example/pages/area/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Area 省市区选择", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-area": "../../dist/area/index" - } + "navigationBarTitleText": "Area 省市区选择" } diff --git a/example/pages/badge/index.json b/example/pages/badge/index.json index 0d3eeb34..9aa95ebd 100644 --- a/example/pages/badge/index.json +++ b/example/pages/badge/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Badge 徽章", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-badge": "../../dist/badge/index", - "van-badge-group": "../../dist/badge-group/index" - } + "navigationBarTitleText": "Badge 徽章" } diff --git a/example/pages/button/index.json b/example/pages/button/index.json index bd094653..b92ec995 100644 --- a/example/pages/button/index.json +++ b/example/pages/button/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Button 按钮", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-button": "../../dist/button/index", - "van-panel": "../../dist/panel/index" - } + "navigationBarTitleText": "Button 按钮" } diff --git a/example/pages/card/index.json b/example/pages/card/index.json index a37ac259..79a0a3c6 100644 --- a/example/pages/card/index.json +++ b/example/pages/card/index.json @@ -1,9 +1,3 @@ { - "navigationBarTitleText": "Card 卡片", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-card": "../../dist/card/index", - "van-button": "../../dist/button/index", - "van-tag": "../../dist/tag/index" - } + "navigationBarTitleText": "Card 卡片" } diff --git a/example/pages/cell/index.json b/example/pages/cell/index.json index 73e559d2..0f202a39 100644 --- a/example/pages/cell/index.json +++ b/example/pages/cell/index.json @@ -1,10 +1,3 @@ { - "navigationBarTitleText": "Cell 单元格", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-cell": "../../dist/cell/index", - "van-icon": "../../dist/icon/index", - "van-tag": "../../dist/tag/index", - "van-cell-group": "../../dist/cell-group/index" - } + "navigationBarTitleText": "Cell 单元格" } diff --git a/example/pages/checkbox/index.json b/example/pages/checkbox/index.json index 8b2d8481..c4e2f3f5 100644 --- a/example/pages/checkbox/index.json +++ b/example/pages/checkbox/index.json @@ -1,10 +1,3 @@ { - "navigationBarTitleText": "Checkbox 复选框", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-checkbox-group": "../../dist/checkbox-group/index", - "van-checkbox": "../../dist/checkbox/index", - "van-cell": "../../dist/cell/index", - "van-cell-group": "../../dist/cell-group/index" - } + "navigationBarTitleText": "Checkbox 复选框" } diff --git a/example/pages/col/index.json b/example/pages/col/index.json index 43707a1a..406ad1ed 100644 --- a/example/pages/col/index.json +++ b/example/pages/col/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Layout 布局", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-row": "../../dist/row/index", - "van-col": "../../dist/col/index" - } + "navigationBarTitleText": "Layout 布局" } diff --git a/example/pages/dashboard/index.json b/example/pages/dashboard/index.json index ec9128a8..2191dad7 100644 --- a/example/pages/dashboard/index.json +++ b/example/pages/dashboard/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Vant Weapp", - "usingComponents": { - "van-panel": "../../dist/panel/index", - "van-cell": "../../dist/cell/index", - "van-cell-group": "../../dist/cell-group/index" - } + "navigationBarTitleText": "Vant Weapp" } diff --git a/example/pages/dialog/index.json b/example/pages/dialog/index.json index cc5b26e6..b5bc7f6b 100644 --- a/example/pages/dialog/index.json +++ b/example/pages/dialog/index.json @@ -1,9 +1,3 @@ { - "navigationBarTitleText": "Dialog 弹出框", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-field": "../../dist/field/index", - "van-button": "../../dist/button/index", - "van-dialog": "../../dist/dialog/index" - } + "navigationBarTitleText": "Dialog 弹出框" } diff --git a/example/pages/field/index.json b/example/pages/field/index.json index 4477ae8a..ced7e35b 100644 --- a/example/pages/field/index.json +++ b/example/pages/field/index.json @@ -1,9 +1,3 @@ { - "navigationBarTitleText": "Field 输入框", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-field": "../../dist/field/index", - "van-button": "../../dist/button/index", - "van-cell-group": "../../dist/cell-group/index" - } + "navigationBarTitleText": "Field 输入框" } diff --git a/example/pages/goods-action/index.json b/example/pages/goods-action/index.json index cbfec5fc..157b60be 100644 --- a/example/pages/goods-action/index.json +++ b/example/pages/goods-action/index.json @@ -1,11 +1,3 @@ { - "navigationBarTitleText": "GoodsAction 商品页行动点", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-goods-action": "../../dist/goods-action/index", - "van-goods-action-icon": "../../dist/goods-action-icon/index", - "van-goods-action-button": "../../dist/goods-action-button/index", - "van-submit-bar": "../../dist/submit-bar/index", - "van-toast": "../../dist/toast/index" - } + "navigationBarTitleText": "GoodsAction 商品页行动点" } diff --git a/example/pages/icon/index.json b/example/pages/icon/index.json index 5a21cf59..0d34d293 100644 --- a/example/pages/icon/index.json +++ b/example/pages/icon/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Icon 图标", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-col": "../../dist/col/index", - "van-icon": "../../dist/icon/index" - } + "navigationBarTitleText": "Icon 图标" } diff --git a/example/pages/loading/index.json b/example/pages/loading/index.json index 8afd6d98..64acf10f 100644 --- a/example/pages/loading/index.json +++ b/example/pages/loading/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Loading 加载", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-loading": "../../dist/loading/index" - } + "navigationBarTitleText": "Loading 加载" } diff --git a/example/pages/nav-bar/index.json b/example/pages/nav-bar/index.json index 2c73f4c4..d1008b32 100644 --- a/example/pages/nav-bar/index.json +++ b/example/pages/nav-bar/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "NavBar 导航栏", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-icon": "../../dist/icon/index", - "van-nav-bar": "../../dist/nav-bar/index" - } + "navigationBarTitleText": "NavBar 导航栏" } diff --git a/example/pages/notice-bar/index.json b/example/pages/notice-bar/index.json index 26286ca5..bd717166 100644 --- a/example/pages/notice-bar/index.json +++ b/example/pages/notice-bar/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "NoticeBar 通告栏", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-notice-bar": "../../dist/notice-bar/index" - } + "navigationBarTitleText": "NoticeBar 通告栏" } diff --git a/example/pages/notify/index.json b/example/pages/notify/index.json index ed738449..a0b1d0dc 100644 --- a/example/pages/notify/index.json +++ b/example/pages/notify/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Notify 消息通知", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-button": "../../dist/button/index", - "van-notify": "../../dist/notify/index" - } + "navigationBarTitleText": "Notify 消息通知" } diff --git a/example/pages/panel/index.json b/example/pages/panel/index.json index 30817633..ac111a79 100644 --- a/example/pages/panel/index.json +++ b/example/pages/panel/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Panel 面板", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-panel": "../../dist/panel/index", - "van-button": "../../dist/button/index" - } + "navigationBarTitleText": "Panel 面板" } diff --git a/example/pages/popup/index.json b/example/pages/popup/index.json index 057f0097..ca281fb4 100644 --- a/example/pages/popup/index.json +++ b/example/pages/popup/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Popup 弹出层", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-popup": "../../dist/popup/index", - "van-button": "../../dist/button/index" - } + "navigationBarTitleText": "Popup 弹出层" } diff --git a/example/pages/progress/index.json b/example/pages/progress/index.json index a47610d0..52821ace 100644 --- a/example/pages/progress/index.json +++ b/example/pages/progress/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Progress 进度条", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-progress": "../../dist/progress/index" - } + "navigationBarTitleText": "Progress 进度条" } diff --git a/example/pages/radio/index.json b/example/pages/radio/index.json index ba953de9..c51422d0 100644 --- a/example/pages/radio/index.json +++ b/example/pages/radio/index.json @@ -1,10 +1,3 @@ { - "navigationBarTitleText": "Radio 单选框", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-radio-group": "../../dist/radio-group/index", - "van-cell-group": "../../dist/cell-group/index", - "van-cell": "../../dist/cell/index", - "van-radio": "../../dist/radio/index" - } + "navigationBarTitleText": "Radio 单选框" } diff --git a/example/pages/search/index.json b/example/pages/search/index.json index 2441410e..374ce514 100644 --- a/example/pages/search/index.json +++ b/example/pages/search/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Search 搜索", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-search": "../../dist/search/index" - } + "navigationBarTitleText": "Search 搜索" } diff --git a/example/pages/slider/index.json b/example/pages/slider/index.json index df7376ec..a2dc9104 100644 --- a/example/pages/slider/index.json +++ b/example/pages/slider/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Slider 滑块", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-slider": "../../dist/slider/index" - } + "navigationBarTitleText": "Slider 滑块" } diff --git a/example/pages/stepper/index.json b/example/pages/stepper/index.json index 838e47f0..367af291 100644 --- a/example/pages/stepper/index.json +++ b/example/pages/stepper/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Stepper 步进器", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-stepper": "../../dist/stepper/index", - "van-panel": "../../dist/panel/index" - } + "navigationBarTitleText": "Stepper 步进器" } diff --git a/example/pages/steps/index.json b/example/pages/steps/index.json index fc4f830c..284a7d5d 100644 --- a/example/pages/steps/index.json +++ b/example/pages/steps/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Steps 步骤条", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-button": "../../dist/button/index", - "van-steps": "../../dist/steps/index" - } + "navigationBarTitleText": "Steps 步骤条" } diff --git a/example/pages/submit-bar/index.json b/example/pages/submit-bar/index.json index 8970856f..d9a1f6df 100644 --- a/example/pages/submit-bar/index.json +++ b/example/pages/submit-bar/index.json @@ -1,9 +1,3 @@ { - "navigationBarTitleText": "SubmitBar 提交订单栏", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-submit-bar": "../../dist/submit-bar/index", - "van-tag": "../../dist/tag/index", - "van-toast": "../../dist/toast/index" - } + "navigationBarTitleText": "SubmitBar 提交订单栏" } diff --git a/example/pages/swipe-cell/index.json b/example/pages/swipe-cell/index.json index adf08de0..152c020a 100644 --- a/example/pages/swipe-cell/index.json +++ b/example/pages/swipe-cell/index.json @@ -1,10 +1,3 @@ { - "navigationBarTitleText": "SwipeCell 滑动单元格", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-swipe-cell": "../../dist/swipe-cell/index", - "van-cell-group": "../../dist/cell-group/index", - "van-cell": "../../dist/cell/index", - "van-dialog": "../../dist/dialog/index" - } + "navigationBarTitleText": "SwipeCell 滑动单元格" } diff --git a/example/pages/switch-cell/index.json b/example/pages/switch-cell/index.json index f8cc9e06..1655ad94 100644 --- a/example/pages/switch-cell/index.json +++ b/example/pages/switch-cell/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "SwitchCell 开关单元格", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-switch-cell": "../../dist/switch-cell/index" - } + "navigationBarTitleText": "SwitchCell 开关单元格" } diff --git a/example/pages/switch/index.json b/example/pages/switch/index.json index 55656a98..a13542b6 100644 --- a/example/pages/switch/index.json +++ b/example/pages/switch/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Switch 开关", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-switch": "../../dist/switch/index", - "van-dialog": "../../dist/dialog/index" - } + "navigationBarTitleText": "Switch 开关" } diff --git a/example/pages/tab/index.json b/example/pages/tab/index.json index 987bfe1a..6ba1d0ef 100644 --- a/example/pages/tab/index.json +++ b/example/pages/tab/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Tab 标签页", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-tab": "../../dist/tab/index", - "van-tabs": "../../dist/tabs/index" - } + "navigationBarTitleText": "Tab 标签页" } diff --git a/example/pages/tabbar/index.json b/example/pages/tabbar/index.json index e2d61606..93a01237 100644 --- a/example/pages/tabbar/index.json +++ b/example/pages/tabbar/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Tabbar 标签栏", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-tabbar": "../../dist/tabbar/index", - "van-tabbar-item": "../../dist/tabbar-item/index" - } + "navigationBarTitleText": "Tabbar 标签栏" } diff --git a/example/pages/tag/index.json b/example/pages/tag/index.json index f627a498..b1ca9e22 100644 --- a/example/pages/tag/index.json +++ b/example/pages/tag/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "Tag 标记", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-tag": "../../dist/tag/index" - } + "navigationBarTitleText": "Tag 标记" } diff --git a/example/pages/toast/index.json b/example/pages/toast/index.json index bcbe4b59..70a49464 100644 --- a/example/pages/toast/index.json +++ b/example/pages/toast/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Toast 轻提示", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-toast": "../../dist/toast/index", - "van-button": "../../dist/button/index" - } + "navigationBarTitleText": "Toast 轻提示" } diff --git a/example/pages/transition/index.json b/example/pages/transition/index.json index 8429b11e..857fa6b1 100644 --- a/example/pages/transition/index.json +++ b/example/pages/transition/index.json @@ -1,8 +1,3 @@ { - "navigationBarTitleText": "Transition 动画", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-cell": "../../dist/cell/index", - "van-transition": "../../dist/transition/index" - } + "navigationBarTitleText": "Transition 动画" } diff --git a/example/pages/tree-select/index.json b/example/pages/tree-select/index.json index bbd2b10d..5863a168 100644 --- a/example/pages/tree-select/index.json +++ b/example/pages/tree-select/index.json @@ -1,7 +1,3 @@ { - "navigationBarTitleText": "TreeSelect 分类选择", - "usingComponents": { - "demo-block": "../../components/demo-block/index", - "van-tree-select": "../../dist/tree-select/index" - } + "navigationBarTitleText": "TreeSelect 分类选择" } diff --git a/packages/action-sheet/README.md b/packages/action-sheet/README.md index 18bbd2a9..dd7f894a 100644 --- a/packages/action-sheet/README.md +++ b/packages/action-sheet/README.md @@ -1,7 +1,7 @@ ## ActionSheet 上拉菜单 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-action-sheet": "path/to/vant-weapp/dist/action-sheet/index" diff --git a/packages/area/README.md b/packages/area/README.md index 432cda4f..f7d3f2ff 100644 --- a/packages/area/README.md +++ b/packages/area/README.md @@ -3,7 +3,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-area": "path/to/vant-weapp/dist/area/index" diff --git a/packages/badge/README.md b/packages/badge/README.md index caafd983..7c7a3da7 100644 --- a/packages/badge/README.md +++ b/packages/badge/README.md @@ -1,7 +1,7 @@ ## Badge 徽章 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-badge": "path/to/vant-weapp/dist/badge/index", diff --git a/packages/card/README.md b/packages/card/README.md index 00e02049..ec856897 100644 --- a/packages/card/README.md +++ b/packages/card/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-card": "path/to/vant-weapp/dist/card/index" diff --git a/packages/cell/README.md b/packages/cell/README.md index f4047198..15ec79af 100644 --- a/packages/cell/README.md +++ b/packages/cell/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-cell": "path/to/vant-weapp/dist/cell/index", diff --git a/packages/checkbox/README.md b/packages/checkbox/README.md index a1b1453f..b93fa693 100644 --- a/packages/checkbox/README.md +++ b/packages/checkbox/README.md @@ -1,7 +1,7 @@ ## Checkbox 复选框 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-checkbox": "path/to/vant-weapp/dist/checkbox/index", diff --git a/packages/col/README.md b/packages/col/README.md index 8908370f..e578d750 100644 --- a/packages/col/README.md +++ b/packages/col/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-row": "path/to/vant-weapp/dist/row/index", diff --git a/packages/dialog/README.md b/packages/dialog/README.md index ae2b742b..daec61a8 100644 --- a/packages/dialog/README.md +++ b/packages/dialog/README.md @@ -4,7 +4,7 @@ Dialog 组件支持函数调用和组件调用两种形式 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-dialog": "path/to/vant-weapp/dist/dialog/index" diff --git a/packages/field/README.md b/packages/field/README.md index e2676791..db65ebe4 100644 --- a/packages/field/README.md +++ b/packages/field/README.md @@ -1,7 +1,7 @@ ## Field 输入框 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-field": "path/to/vant-weapp/dist/field/index" diff --git a/packages/goods-action/README.md b/packages/goods-action/README.md index 326ab80e..d4bd0aeb 100644 --- a/packages/goods-action/README.md +++ b/packages/goods-action/README.md @@ -1,7 +1,7 @@ ## goodsAction 商品页行动点 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-goods-action": "path/to/vant-weapp/dist/goods-action/index", diff --git a/packages/icon/README.md b/packages/icon/README.md index a9fef151..06f53e2d 100644 --- a/packages/icon/README.md +++ b/packages/icon/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-icon": "path/to/vant-weapp/dist/icon/index" diff --git a/packages/loading/README.md b/packages/loading/README.md index a1138326..dd28ffa5 100644 --- a/packages/loading/README.md +++ b/packages/loading/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-loading": "path/to/vant-weapp/dist/loading/index" diff --git a/packages/nav-bar/README.md b/packages/nav-bar/README.md index 1840ab44..817f5dbb 100644 --- a/packages/nav-bar/README.md +++ b/packages/nav-bar/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-nav-bar": "path/to/vant-weapp/dist/nav-bar/index" diff --git a/packages/notice-bar/README.md b/packages/notice-bar/README.md index f8c77acf..ee6497c7 100644 --- a/packages/notice-bar/README.md +++ b/packages/notice-bar/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-notice-bar": "path/to/vant-weapp/dist/notice-bar/index" diff --git a/packages/notify/README.md b/packages/notify/README.md index 986b1595..61b47abd 100644 --- a/packages/notify/README.md +++ b/packages/notify/README.md @@ -1,7 +1,7 @@ ## Notify 消息提示 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json { "usingComponents": { diff --git a/packages/panel/README.md b/packages/panel/README.md index 1a8af858..0dab7c7d 100644 --- a/packages/panel/README.md +++ b/packages/panel/README.md @@ -1,7 +1,7 @@ ## Panel 面板 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-panel": "path/to/vant-weapp/dist/panel/index" diff --git a/packages/popup/README.md b/packages/popup/README.md index d305c373..5f14b0f0 100644 --- a/packages/popup/README.md +++ b/packages/popup/README.md @@ -1,7 +1,7 @@ ## Popup 弹出层 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-popup": "path/to/vant-weapp/dist/popup/index" diff --git a/packages/progress/README.md b/packages/progress/README.md index d2c59f55..cf3f284f 100644 --- a/packages/progress/README.md +++ b/packages/progress/README.md @@ -1,7 +1,7 @@ ## Progress 进度条 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-progress": "path/to/vant-weapp/dist/progress/index" diff --git a/packages/radio/README.md b/packages/radio/README.md index f786ee53..abf8419c 100644 --- a/packages/radio/README.md +++ b/packages/radio/README.md @@ -1,7 +1,7 @@ ## Radio 单选框 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-radio": "path/to/vant-weapp/dist/radio/index", diff --git a/packages/search/README.md b/packages/search/README.md index 65a8bcd1..c6ee3c9b 100644 --- a/packages/search/README.md +++ b/packages/search/README.md @@ -1,7 +1,7 @@ ## Search 搜索 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-search": "/packages/search/index" diff --git a/packages/slider/README.md b/packages/slider/README.md index 8b54fd46..6637d211 100644 --- a/packages/slider/README.md +++ b/packages/slider/README.md @@ -1,7 +1,7 @@ ## Slider 滑块 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-slider": "/packages/slider/index" diff --git a/packages/stepper/README.md b/packages/stepper/README.md index e3a8e32d..665a2982 100644 --- a/packages/stepper/README.md +++ b/packages/stepper/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-stepper": "path/to/vant-weapp/dist/stepper/index" diff --git a/packages/steps/README.md b/packages/steps/README.md index bb1ed64f..dd274740 100644 --- a/packages/steps/README.md +++ b/packages/steps/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-steps": "path/to/vant-weapp/dist/steps/index" diff --git a/packages/submit-bar/README.md b/packages/submit-bar/README.md index 9ee2b4e6..71e23129 100644 --- a/packages/submit-bar/README.md +++ b/packages/submit-bar/README.md @@ -1,7 +1,7 @@ ## SubmitBar 提交订单栏 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-submit-bar": "path/to/vant-weapp/dist/submit-bar/index" diff --git a/packages/swipe-cell/README.md b/packages/swipe-cell/README.md index 0dc9da9c..996b9e34 100644 --- a/packages/swipe-cell/README.md +++ b/packages/swipe-cell/README.md @@ -1,7 +1,7 @@ ## SwipeCell 滑动单元格 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-swipe-cell": "path/to/vant-weapp/dist/swipe-cell/index" diff --git a/packages/switch-cell/README.md b/packages/switch-cell/README.md index 9b49deba..3541383a 100644 --- a/packages/switch-cell/README.md +++ b/packages/switch-cell/README.md @@ -1,7 +1,7 @@ ## SwitchCell 开关单元格 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-switch-cell": "path/to/vant-weapp/dist/switch-cell/index" diff --git a/packages/switch/README.md b/packages/switch/README.md index d606d005..e9c3b866 100644 --- a/packages/switch/README.md +++ b/packages/switch/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-switch": "path/to/vant-weapp/dist/switch/index" diff --git a/packages/tab/README.md b/packages/tab/README.md index 47671def..859fcae8 100644 --- a/packages/tab/README.md +++ b/packages/tab/README.md @@ -1,7 +1,7 @@ ## Tab 标签页 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-tab": "path/to/vant-weapp/dist/tab/index", diff --git a/packages/tabbar/README.md b/packages/tabbar/README.md index 33f51806..34c16f1a 100644 --- a/packages/tabbar/README.md +++ b/packages/tabbar/README.md @@ -1,7 +1,7 @@ ## Tabbar 标签栏 ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-tabbar": "/packages/tabbar/index", diff --git a/packages/tag/README.md b/packages/tag/README.md index 7982e7ed..b7f65dcf 100644 --- a/packages/tag/README.md +++ b/packages/tag/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-tag": "path/to/vant-weapp/dist/tag/index" diff --git a/packages/toast/README.md b/packages/toast/README.md index 4a0775ab..c0e8b435 100644 --- a/packages/toast/README.md +++ b/packages/toast/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-toast": "path/to/vant-weapp/dist/toast/index" diff --git a/packages/transition/README.md b/packages/transition/README.md index fddae642..8b4dc0dc 100644 --- a/packages/transition/README.md +++ b/packages/transition/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-transition": "path/to/vant-weapp/dist/transition/index" diff --git a/packages/tree-select/README.md b/packages/tree-select/README.md index 6b9be1f2..13194395 100644 --- a/packages/tree-select/README.md +++ b/packages/tree-select/README.md @@ -2,7 +2,7 @@ ### 使用指南 -在 index.json 中引入组件 +在 app.json 或 index.json 中引入组件 ```json "usingComponents": { "van-tree-select": "path/to/vant-weapp/dist/tree-select/index"