Pug is a template engine heavily influenced by Haml. This plugin allows you to use it to create pages and layouts.
Import this plugin in your
_config.ts file to use it:
import lume from "lume/mod.ts"; import pug from "lume/plugins/pug.ts"; const site = lume(); site.use(pug()); export default site;
Add a file with
.pug extension in the
_includes directory. Use the front matter to set data for the template.
title: Welcome to my page intro: This is my first post using Lume. I hope you like it! doctype html html head title= title body include partials/nav.pug p= title
Note that the paths passed to
include are relative to
Creating pages is the same as creating layouts; just place the
.pug file outside the