-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
translation: tutorial/if.md #71
Conversation
Merge master to feature-18n
source/_posts/en/tutorial/if.md
Outdated
@@ -8,43 +8,43 @@ categories: | |||
s-if | |||
------ | |||
|
|||
通过 **s-if** 指令,我们可以为元素指定条件。当条件成立时元素可见,当条件不成立时元素不存在。 | |||
**s-if** directive can be used for conditional rendering. The element will be rendered if and only if the condition is evaluated as true. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is evaluated as true -> evaluates to
source/_posts/en/tutorial/if.md
Outdated
|
||
```html | ||
<span s-if="isOK">Hello San!</span> | ||
``` | ||
|
||
**s-if** 指令的值可以是任何类型的[表达式](../template/#表达式)。 | ||
The [expression](../template/#Expression) for **s-if** can be of any type. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The s-if
directive can contain any type of expression
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
当前的这个翻译,给人的感觉是“if的表达式可以返回任何类型”,和上面的“要boolean”有点冲突
source/_posts/en/tutorial/if.md
Outdated
|
||
s-elif | ||
------ | ||
|
||
`> 3.2.3` | ||
|
||
**s-elif** 指令可以给 **s-if** 增加一个额外条件分支块。**s-elif** 指令的值可以是任何类型的[表达式](../template/#表达式)。 | ||
**s-elif** directive can be used to add a conditional branch for **s-if**. The [expression](../template/#Expression) for **s-elif** can be of any type. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
conditional branch -> condition branch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
后面半句同上
working on #65