有没有办法在其父布局中访问子布局中定义的 YFM 属性?
例如,给定一个子布局 page.hbs:
---
layout: wrapper.hbs
no_header: true
----
<div class="wrapper">{{> body }}</div>
我想访问no_header
父布局 wrapper.hbs 中 page.hbs 中定义的 YFM 属性:
<html>
<body>
{{#unless layout.no_header}}<header></header>{{/if}}
{{> body }}
</body>
</html>