From 94ccd3a658615072c820aa1b5ee7fe8179e93a1a Mon Sep 17 00:00:00 2001 From: fbwfbi Date: Sat, 3 Sep 2016 09:03:08 +0800 Subject: [PATCH] :pencil: docs(gitbook): fix data option (#305) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit data属性应该是属于vue实例的,而不是validators选项 --- docs/zh-cn/async.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/zh-cn/async.md b/docs/zh-cn/async.md index 228a0ba..976f701 100644 --- a/docs/zh-cn/async.md +++ b/docs/zh-cn/async.md @@ -41,10 +41,10 @@ ValidationError.prototype.constructor = ValidationError // exmpale with ES2015 export default { - validators: { - data () { + data () { return { checking: false } - }, + }, + validators: { exist (val) { this.vm.checking = true // spinner on return fetch('/validations/exist', {