mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-05 05:42:44 +08:00
docs: add new document site URL (#12902)
This commit is contained in:
parent
8128b330d3
commit
24e4574993
@ -17,7 +17,7 @@
|
||||
|
||||
·
|
||||
|
||||
<a href="https://vant-ui.github.io/vant">文档站</a>
|
||||
<a href="https://vant.pro/vant/">Documentation (backup)</a>
|
||||
|
||||
·
|
||||
|
||||
@ -98,7 +98,7 @@ const app = createApp();
|
||||
app.use(Button);
|
||||
```
|
||||
|
||||
See more in [Quickstart](https://vant-ui.github.io/vant#/en-US/quickstart).
|
||||
See more in [Quickstart](https://vant-ui.github.io/vant/#/en-US/quickstart).
|
||||
|
||||
## Browser Support
|
||||
|
||||
@ -133,8 +133,9 @@ Vant 3/4 supports modern browsers and Chrome >= 51、iOS >= 10.0 (same as Vue 3)
|
||||
|
||||
## Links
|
||||
|
||||
- [Documentation](https://vant-ui.github.io/vant)
|
||||
- [Changelog](https://vant-ui.github.io/vant#/en-US/changelog)
|
||||
- [Documentation](https://vant-ui.github.io/vant/)
|
||||
- [Documentation (backup)](https://vant.pro/vant/)
|
||||
- [Changelog](https://vant-ui.github.io/vant/#/en-US/changelog)
|
||||
- [Discussions](https://github.com/vant-ui/vant/discussions)
|
||||
|
||||
## Preview
|
||||
|
@ -13,7 +13,11 @@
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
🌈 <a href="https://vant-ui.github.io/vant">文档网站</a>
|
||||
🌈 <a href="https://vant.pro/vant/">文档网站(国内)</a>
|
||||
|
||||
·
|
||||
|
||||
<a href="https://vant-ui.github.io/vant">文档网站(GitHub)</a>
|
||||
</p>
|
||||
|
||||
---
|
||||
@ -22,7 +26,7 @@
|
||||
|
||||
Vant 是一个**轻量、可定制的移动端组件库**,于 2017 年开源。
|
||||
|
||||
目前 Vant 官方提供了 [Vue 2 版本](https://vant-ui.github.io/vant/v2)、[Vue 3 版本](https://vant-ui.github.io/vant)和[微信小程序版本](https://vant-ui.github.io/vant-weapp),并由社区团队维护 [React 版本](https://github.com/3lang3/react-vant)和[支付宝小程序版本](https://github.com/ant-move/Vant-Aliapp)。
|
||||
目前 Vant 官方提供了 [Vue 2 版本](https://vant-ui.github.io/vant/v2/)、[Vue 3 版本](https://vant-ui.github.io/vant/)和[微信小程序版本](https://vant-ui.github.io/vant-weapp/),并由社区团队维护 [React 版本](https://github.com/3lang3/react-vant)和[支付宝小程序版本](https://github.com/ant-move/Vant-Aliapp)。
|
||||
|
||||
## 特性
|
||||
|
||||
@ -96,7 +100,7 @@ const app = createApp();
|
||||
app.use(Button);
|
||||
```
|
||||
|
||||
vant 也支持按需引入、CDN 引入等方式,详细说明见 [快速上手](https://vant-ui.github.io/vant#/zh-CN/quickstart).
|
||||
vant 也支持按需引入、CDN 引入等方式,详细说明见 [快速上手](https://vant-ui.github.io/vant/#/zh-CN/quickstart).
|
||||
|
||||
## 浏览器支持
|
||||
|
||||
@ -135,8 +139,8 @@ Vant 3/4 支持现代浏览器以及 Chrome >= 51、iOS >= 10.0(与 Vue 3 一
|
||||
|
||||
## 链接
|
||||
|
||||
- [详细文档](https://vant-ui.github.io/vant)
|
||||
- [更新日志](https://vant-ui.github.io/vant#/zh-CN/changelog)
|
||||
- [详细文档](https://vant-ui.github.io/vant/)
|
||||
- [更新日志](https://vant-ui.github.io/vant/#/zh-CN/changelog)
|
||||
- [Discussions 讨论区](https://github.com/vant-ui/vant/discussions)
|
||||
|
||||
## 手机预览
|
||||
|
@ -334,7 +334,7 @@ module.exports = {
|
||||
versions: [
|
||||
{
|
||||
label: 'v1',
|
||||
link: 'https://vant-ui.github.io/vant/v1/',
|
||||
link: '/v1/',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
@ -314,7 +314,7 @@ module.exports = {
|
||||
versions: [
|
||||
{
|
||||
label: 'v1',
|
||||
link: 'https://vant-ui.github.io/vant/v1/',
|
||||
link: '/v1/',
|
||||
},
|
||||
],
|
||||
},
|
||||
|
@ -4,8 +4,8 @@
|
||||
|
||||
The current document is the changelog of Vant 4, other versions:
|
||||
|
||||
- [Vant 2 Changelog](https://vant-ui.github.io/vant/v2/#/en-US/changelog)
|
||||
- [Vant 3 Changelog](https://vant-ui.github.io/vant/v3/#/en-US/changelog)
|
||||
- [Vant 2 Changelog](/vant/v2/#/en-US/changelog)
|
||||
- [Vant 3 Changelog](/vant/v3/#/en-US/changelog)
|
||||
|
||||
### Intro
|
||||
|
||||
|
@ -4,8 +4,8 @@
|
||||
|
||||
当前文档为 Vant 4 的更新日志,其他版本请参考:
|
||||
|
||||
- [Vant 2 更新日志](https://vant-ui.github.io/vant/v2/#/zh-CN/changelog)
|
||||
- [Vant 3 更新日志](https://vant-ui.github.io/vant/v3/#/zh-CN/changelog)
|
||||
- [Vant 2 更新日志](/vant/v2/#/zh-CN/changelog)
|
||||
- [Vant 3 更新日志](/vant/v3/#/zh-CN/changelog)
|
||||
|
||||
### 介绍
|
||||
|
||||
@ -1119,7 +1119,7 @@ Vant 遵循 [Semver](https://semver.org/lang/zh-CN/) 语义化版本规范。
|
||||
|
||||
`2022-11-26`
|
||||
|
||||
> 完整内容请移步:[「4.0 更新介绍」](https://vant-ui.github.io/vant/#/zh-CN/release-note-v4)
|
||||
> 完整内容请移步:[「4.0 更新介绍」](/vant/#/zh-CN/release-note-v4)
|
||||
|
||||
**Feature**
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
Vant 是一个**轻量、可定制的移动端组件库**,于 2017 年开源。
|
||||
|
||||
目前 Vant 官方提供了 [Vue 2 版本](https://vant-ui.github.io/vant/v2)、[Vue 3 版本](https://vant-ui.github.io/vant)和[微信小程序版本](https://vant-ui.github.io/vant-weapp),并由社区团队维护 [React 版本](https://github.com/3lang3/react-vant)和[支付宝小程序版本](https://github.com/ant-move/Vant-Aliapp)。
|
||||
目前 Vant 官方提供了 [Vue 2 版本](/vant/v2/)、[Vue 3 版本](/vant/)和[微信小程序版本](/vant-weapp/),并由社区团队维护 [React 版本](https://github.com/3lang3/react-vant)和[支付宝小程序版本](https://github.com/ant-move/Vant-Aliapp)。
|
||||
|
||||
### 特性
|
||||
|
||||
@ -32,7 +32,7 @@ Vant 是一个**轻量、可定制的移动端组件库**,于 2017 年开源
|
||||
|
||||
### 版本提示
|
||||
|
||||
你当前浏览的是 **Vant 4.x 版本** 的文档,适用于 Vue 3 开发。如果你在使用 Vue 2,请浏览 [Vant 2 文档](https://vant-ui.github.io/vant/v2)。
|
||||
你当前浏览的是 **Vant 4.x 版本** 的文档,适用于 Vue 3 开发。如果你在使用 Vue 2,请浏览 [Vant 2 文档](/vant/v2/)。
|
||||
|
||||
### 脚手架
|
||||
|
||||
|
@ -10,7 +10,7 @@ In this iteration, Vant supports the dark mode, adds five new components, improv
|
||||
|
||||
**Vant 4.0 supports switching all components to dark mode.**
|
||||
|
||||
Simply set the `theme` attribute of the [ConfigProvider component](https://vant-ui.github.io/vant/#/en-US/config-provider) to `dark` to switch to dark mode, which will switch all Vant components on the page to a dark style.
|
||||
Simply set the `theme` attribute of the [ConfigProvider component](/vant/#/en-US/config-provider) to `dark` to switch to dark mode, which will switch all Vant components on the page to a dark style.
|
||||
|
||||
```html
|
||||
<van-config-provider theme="dark">
|
||||
@ -28,11 +28,11 @@ At the same time, the Vant 4.0 document also supports switching to dark mode:
|
||||
|
||||
**Vant 4.0 contains the following new components:**
|
||||
|
||||
- [BackTop](https://vant-ui.github.io/vant/#/en-US/back-top): Used to back to the top of the page.
|
||||
- [TimePicker](https://vant-ui.github.io/vant/#/en-US/time-picker): Used for time selection, including hours, minutes, and seconds.
|
||||
- [DatePicker](https://vant-ui.github.io/vant/#/en-US/time-picker): Used for date selection, including year, month, and day.
|
||||
- [PickerGroup](https://vant-ui.github.io/vant/#/en-US/picker-group): Used to combine multiple Picker components, allow users to select multiple value.
|
||||
- [SkeletonItems](https://vant-ui.github.io/vant/#/en-US/skeleton): Customize the skeleton through subcomponents such as SkeletonTitle, SkeletonImage, and SkeletonAvatar.
|
||||
- [BackTop](/vant/#/en-US/back-top): Used to back to the top of the page.
|
||||
- [TimePicker](/vant/#/en-US/time-picker): Used for time selection, including hours, minutes, and seconds.
|
||||
- [DatePicker](/vant/#/en-US/time-picker): Used for date selection, including year, month, and day.
|
||||
- [PickerGroup](/vant/#/en-US/picker-group): Used to combine multiple Picker components, allow users to select multiple value.
|
||||
- [SkeletonItems](/vant/#/en-US/skeleton): Customize the skeleton through subcomponents such as SkeletonTitle, SkeletonImage, and SkeletonAvatar.
|
||||
|
||||
Among them, TimePicker and DatePicker are split from the old DatetimePicker component, and the DatetimePicker component is removed. You can use PickerGroup to get the interactive effect of selecting the date and time at the same time.
|
||||
|
||||
@ -86,7 +86,7 @@ In the early days, most component libraries used `babel-plugin-import` to achiev
|
||||
import { showToast, buttonProps } from 'vant';
|
||||
```
|
||||
|
||||
In terms of bundle size, removing `babel-plugin-import` will not affect on the JS size of the project, because Vant supports tree shaking by default to remove unnecessary JS code by default, and CSS code can be imported on demand via [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components). For detailed usage, please refer to ["Quick Start"](https://vant-ui.github.io/vant/#/en-US/quickstart).
|
||||
In terms of bundle size, removing `babel-plugin-import` will not affect on the JS size of the project, because Vant supports tree shaking by default to remove unnecessary JS code by default, and CSS code can be imported on demand via [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components). For detailed usage, please refer to ["Quick Start"](/vant/#/en-US/quickstart).
|
||||
|
||||
### Style variable type hints
|
||||
|
||||
@ -110,7 +110,7 @@ In the previous version, the API design of the `Picker` component was not sensib
|
||||
|
||||
To solve the above problems, we refactored the `Picker` component in Vant 4.0, and also refactored the `Area` and `DatetimePicker` components derived from `Picker`.
|
||||
|
||||
If these three components are used in your project, please read the ["Upgrade Guide"](https://vant-ui.github.io/vant/#/en-US/migrate-from-v3) to upgrade.
|
||||
If these three components are used in your project, please read the ["Upgrade Guide"](/vant/#/en-US/migrate-from-v3) to upgrade.
|
||||
|
||||
### Component Utils Adjustment
|
||||
|
||||
@ -209,9 +209,9 @@ npm add stylelint@13 @vant/stylelint-config
|
||||
|
||||
### Version Information
|
||||
|
||||
**Currently both [Vant official website](https://vant-ui.github.io/vant/) and npm latest tag point to Vant 4.0.**
|
||||
**Currently both [Vant official website](/vant/) and npm latest tag point to Vant 4.0.**
|
||||
|
||||
We have prepared a complete upgrade guide for Vant 4.0, please read [Upgrade from v3 to v4](https://vant-ui.github.io/vant/#/en-US/migrate-from-v3) to upgrade.
|
||||
We have prepared a complete upgrade guide for Vant 4.0, please read [Upgrade from v3 to v4](/vant/#/en-US/migrate-from-v3) to upgrade.
|
||||
|
||||
At the same time, Vant 3.x will also enter the maintenance status, and the maintenance status of each version of Vant is as follows:
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
**Vant 4.0 支持切换所有组件为深色模式。**
|
||||
|
||||
只需要把 [ConfigProvider 组件](https://vant-ui.github.io/vant/#/zh-CN/config-provider)的 `theme` 属性设置为 `dark`,即可切换为深色模式,将页面上的所有 Vant 组件变成深色风格。
|
||||
只需要把 [ConfigProvider 组件](/vant/#/zh-CN/config-provider)的 `theme` 属性设置为 `dark`,即可切换为深色模式,将页面上的所有 Vant 组件变成深色风格。
|
||||
|
||||
```html
|
||||
<van-config-provider theme="dark">
|
||||
@ -28,11 +28,11 @@
|
||||
|
||||
**Vant 4.0 包含以下新组件:**
|
||||
|
||||
- [BackTop 回到顶部](https://vant-ui.github.io/vant/#/zh-CN/back-top):返回页面顶部的操作按钮。
|
||||
- [TimePicker 时间选择器](https://vant-ui.github.io/vant/#/zh-CN/time-picker):用于时间选择,包括时、分、秒。
|
||||
- [DatePicker 日期选择器](https://vant-ui.github.io/vant/#/zh-CN/date-picker):用于日期选择,包括年、月、日。
|
||||
- [PickerGroup 选择器组](https://vant-ui.github.io/vant/#/zh-CN/picker-group):用于结合多个 Picker 选择器组件,在一次交互中完成多个值的选择。
|
||||
- [Skeleton 骨架屏子组件](https://vant-ui.github.io/vant/#/zh-CN/skeleton):通过 SkeletonTitle、SkeletonImage、SkeletonAvatar 等子组件来自定义骨架屏。
|
||||
- [BackTop 回到顶部](/vant/#/zh-CN/back-top):返回页面顶部的操作按钮。
|
||||
- [TimePicker 时间选择器](/vant/#/zh-CN/time-picker):用于时间选择,包括时、分、秒。
|
||||
- [DatePicker 日期选择器](/vant/#/zh-CN/date-picker):用于日期选择,包括年、月、日。
|
||||
- [PickerGroup 选择器组](/vant/#/zh-CN/picker-group):用于结合多个 Picker 选择器组件,在一次交互中完成多个值的选择。
|
||||
- [Skeleton 骨架屏子组件](/vant/#/zh-CN/skeleton):通过 SkeletonTitle、SkeletonImage、SkeletonAvatar 等子组件来自定义骨架屏。
|
||||
|
||||
其中,TimePicker 和 DatePicker 由旧版的 DatetimePicker 组件拆分而来,DatetimePicker 组件不再提供。你可以通过 PickerGroup 来实现同时选择日期和时间的交互效果。
|
||||
|
||||
@ -86,7 +86,7 @@
|
||||
import { showToast, buttonProps } from 'vant';
|
||||
```
|
||||
|
||||
在包体积方面,移除 `babel-plugin-import` 对项目的 JS 体积不会有影响,因为 Vant 默认支持通过 Tree Shaking 来移除不需要的 JS 代码,而 CSS 代码可以通过 [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components) 插件实现按需引入,详细用法请参考 [「快速上手」](https://vant-ui.github.io/vant/#/zh-CN/quickstart)。
|
||||
在包体积方面,移除 `babel-plugin-import` 对项目的 JS 体积不会有影响,因为 Vant 默认支持通过 Tree Shaking 来移除不需要的 JS 代码,而 CSS 代码可以通过 [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components) 插件实现按需引入,详细用法请参考 [「快速上手」](/vant/#/zh-CN/quickstart)。
|
||||
|
||||
### 样式变量类型提示
|
||||
|
||||
@ -110,7 +110,7 @@ Vant 提供了 700 多个样式变量,你可以通过 CSS 代码或 `ConfigPro
|
||||
|
||||
为了解决上述问题,我们在 Vant 4.0 中对 `Picker` 组件进行了重构,同时也重构了基于 `Picker` 派生出的 `Area` 和 `DatetimePicker` 组件。
|
||||
|
||||
如果你的项目中使用了这三个组件,请阅读 [「升级指南」](https://vant-ui.github.io/vant/#/zh-CN/migrate-from-v3) 进行升级。
|
||||
如果你的项目中使用了这三个组件,请阅读 [「升级指南」](/vant/#/zh-CN/migrate-from-v3) 进行升级。
|
||||
|
||||
### 组件工具函数调整
|
||||
|
||||
@ -209,9 +209,9 @@ npm add stylelint@13 @vant/stylelint-config
|
||||
|
||||
### 版本信息
|
||||
|
||||
**目前 [Vant 官网](https://vant-ui.github.io/vant/) 和 npm latest 标签均已指向 Vant 4.0。**
|
||||
**目前 [Vant 官网](/vant/) 和 npm latest 标签均已指向 Vant 4.0。**
|
||||
|
||||
我们为 Vant 4.0 准备了完整的升级指南,请阅读 [从 v3 升级到 v4](https://vant-ui.github.io/vant/#/zh-CN/migrate-from-v3) 进行升级。
|
||||
我们为 Vant 4.0 准备了完整的升级指南,请阅读 [从 v3 升级到 v4](/vant/#/zh-CN/migrate-from-v3) 进行升级。
|
||||
|
||||
同时,Vant 3.x 也会进入维护状态,后续 Vant 各个版本的维护状态如下:
|
||||
|
||||
|
@ -53,7 +53,7 @@ location.href = location.href.replace('youzan.github.io', 'vant-ui.github.io');
|
||||
links: [
|
||||
{
|
||||
logo: 'https://fastly.jsdelivr.net/npm/@vant/assets/weapp.svg',
|
||||
url: 'https://vant-ui.github.io/vant-weapp/',
|
||||
url: '/vant-weapp/',
|
||||
},
|
||||
{
|
||||
logo: 'https://fastly.jsdelivr.net/npm/@vant/assets/github.svg',
|
||||
|
Loading…
x
Reference in New Issue
Block a user