From a33d304d532c02559ef5a7179be865ca4af5cdaa Mon Sep 17 00:00:00 2001 From: Alan Wang Date: Tue, 26 Apr 2022 20:57:15 +0800 Subject: [PATCH] docs(vant): keep the doc consistent with the demo code (#10554) --- packages/vant/src/form/README.md | 4 ++-- packages/vant/src/form/README.zh-CN.md | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/vant/src/form/README.md b/packages/vant/src/form/README.md index e5d0b9686..1661635a9 100644 --- a/packages/vant/src/form/README.md +++ b/packages/vant/src/form/README.md @@ -115,7 +115,7 @@ export default { setup() { const value1 = ref(''); const value2 = ref(''); - const value3 = ref(''); + const value3 = ref('abc'); const value4 = ref(''); const pattern = /\d{6}/; @@ -129,7 +129,7 @@ export default { setTimeout(() => { Toast.clear(); - resolve(/\d{6}/.test(val)); + resolve(val === '1234'); }, 1000); }); diff --git a/packages/vant/src/form/README.zh-CN.md b/packages/vant/src/form/README.zh-CN.md index 3b3c36d24..6b58ff3e6 100644 --- a/packages/vant/src/form/README.zh-CN.md +++ b/packages/vant/src/form/README.zh-CN.md @@ -123,7 +123,7 @@ export default { setup() { const value1 = ref(''); const value2 = ref(''); - const value3 = ref(''); + const value3 = ref('abc'); const value4 = ref(''); const pattern = /\d{6}/; @@ -140,7 +140,7 @@ export default { setTimeout(() => { Toast.clear(); - resolve(/\d{6}/.test(val)); + resolve(val === '1234'); }, 1000); });