Mastodon

Torgny Bjers Code Berserker

Supporting Liquid Templates in Wintersmith

We’ve gotten used to Liquid from using Jekyll and Octopress. When we took Wintersmith for a spin we sort of missed Liquid. So we created a template plugin for Liquid that uses the liquid-node module to render Liquid templates.

Liquid plugin for Wintersmith, uses liquid-node to take advantage of asynchronous behavior. The liquid-node module uses Q internally and thus we can take advantage of this in our template plugin.

Template plugins for Wintersmith are quite easy to write. We published ours on npm after a few minutes after initially having been confounded by CoffeeScript. Bonus: now we know how to write CoffeeScript!

Installation instructions

Navigate to the folder you created with wintersmith new and run

$ npm install wintersmith-liquid --save

Once you have installed the plugin you need to modify your config.json and add wintersmith-liquid to the list of plugins for your site.

Templates with the .html extensions are parsed with Liquid.

Clone wintersmith-liquid on Bitbucket