Skip to content
This repository was archived by the owner on Aug 8, 2022. It is now read-only.

Commit d201594

Browse files
Update component-props.md (#705)
* Update component-props.md 添加对 prop 中 隐式转换 Boolean 的条件。 * Apply suggestions from code review Co-authored-by: Jinjiang <zhaojinjiang@me.com>
1 parent a17bf3c commit d201594

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/guide/component-props.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ props: {
6262

6363
```html
6464
<!-- 包含该 prop 没有值的情况在内,都意味着 `true`。 -->
65+
<!-- 如果没有在 props 中把 is-published 的类型设置为 Boolean,则这里的值为空字符串,而不是“true” 。 -->
6566
<blog-post is-published></blog-post>
6667

6768
<!-- 即便 `false` 是静态的,我们仍然需要 `v-bind` 来告诉 Vue -->

0 commit comments

Comments
 (0)