我正在使用nanoc,我希望我的index.html指向特定的布局,所以我创建了该布局,它被称为nosidebar.html
我的规则如下:
compile 'index.html' do
layout 'nosidebar'
end
这似乎不起作用。我究竟做错了什么?
您可以随时添加以下内容:
compile '*' do
if item.binary?
# don’t filter binary items
else
layout item[:layout] || 'default'
end
end
这意味着您可以通过添加以下内容来决定文件上的模板:
---
layout: nosidebar
---
在文件的 yaml 前面。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)