Home How to specify layout in nanoc?
Reply: 0

How to specify layout in nanoc?

user819
1#
user819 Published in June 19, 2018, 4:29 pm

In Jekyll, we write layout structure in a HTML file and put it in _layout folder. Say, the _layout folder has file named welcome.html, for a webpage to use it, we simply specify as follows:

---
title: Awesome webpage
layout: welcome
---

How to do the same when using nanoc? I thought it works the same way, but unfortunately, it seems like not picking up the welcome template. It is just picking up the default.html template.

Is it because of the file called rule which has the following lines?

compile '/' do
  filter :erb
  layout 'default'
end

I want only one specific file to pick up the welcome layout. How to do it?

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.344261 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO