【发布时间】:2016-02-15 08:37:43
【问题描述】:
Stencil 中是否有可用的自定义助手来链接多个条件而不是嵌套它们?
{{#if template_file '!==' 'pages/home'}}
{{#if template_file '!==' 'pages/product'}}
{{#if template_file '!==' 'pages/category'}}
...
{{/if}}
{{/if}}
{{/if}}
在这种情况下可以使用“任何”帮助器吗?
【问题讨论】:
-
你能解释一下你想要做什么需要“链”而不是嵌套吗?