2
我試圖通過使用動態屬性名稱的對象迭代它似乎並不奏效:迭代通過在handlebars.js動態屬性對象
{{#each orders["order" + name] }}
甚至沒有這似乎是工作
{{#each orders["orderDemo"] }}
但這:
{{#each orders.orderDemo }}
任何解決方案來處理動態屬性名取決於其他條件或迭代?
在我的情況,我有:
{{#each types}}
{{#each orders[type] }}
<table>....</table>
{{/each}}
{{/each}}