From 53b26623f8560da1bc8cf973c4a5337a3baf5314 Mon Sep 17 00:00:00 2001 From: Andrey Breeze Date: Tue, 19 Jan 2016 19:01:35 +0300 Subject: [PATCH] Update forms.md I found that in case of multiple checkboxes we MUST specify the `checkedNames` as array for the Vue constructor. If we don't do it, we will get true/false instead of array. But guide don't tell us about it. So, this is unclearly. --- src/guide/forms.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/guide/forms.md b/src/guide/forms.md index c6b5a3ab04..2e79800df9 100644 --- a/src/guide/forms.md +++ b/src/guide/forms.md @@ -66,6 +66,16 @@ Mutiple checkboxes, bound to the same Array:
Checked names: {{ checkedNames | json }} ``` + +``` js +new Vue({ + el: '...', + data: { + checkedNames: [] + } +}) +``` + {% raw %}