本文介绍了如何在ember handlebar中使用if语句?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个如下的说明
{{#if IsValid}}
但我想知道如何使用if语句不像下面
but i want to know that how can i use if statement with not like below
{{#if not IsValid}}
推荐答案
简单问题的简单答案:
{{#unless isValid}}
{{/unless}}
还要记住,你可以插入一个 {{else }}
之间 {{#if}}
或 {{#unless}}
和结束标签。
Also keep in mind that you can insert an {{else}}
in between an {{#if}}
or {{#unless}}
and the closing tag.
这篇关于如何在ember handlebar中使用if语句?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!