liquid-crystal

A port of the Liquid template engine to Crystal

Build Status

Liquid template engine

A port of the Liquid template engine to Crystal

Usage

require "liquid-crystal"

markup = "{% if user %}
<p>Hello {{ user.name }}!</p>
{% endif %}"

template = Liquid::Template.parse template

result = template.render({"user" => {"name" => "Matz"}})

# <p>Hello Matz</p>

Development Status

It's still a WIP, however much of the code and specs have been converted. Work needs to be done for added stability, adding missing filters, implementing missing tests

Todo

Missing standard filters

  • sort
  • map

Missing tests

  • Template tokenize tests
  • All tests that expect an error to not be raised

Support for procs in templates

  • I'm not sure if I actually want to support this
Repository

liquid-crystal

Owner
Statistic
  • 8
  • 1
  • 0
  • 0
  • 0
  • 11 months ago
  • June 9, 2016
License

Other

Links
Synced at

Sun, 22 Jun 2025 23:39:59 GMT

Languages