liq
4.7/53
liquidjs
npm i liquidjs
liq

liquidjs

A simple, expressive, safe and Shopify compatible template engine in pure JavaScript.

by Jun Yang

9.37.0 (see all)License:MITTypeScript:Built-InCategories:Express HTML Templating Engine
npm i liquidjs
Readme

liquidjs

npm version npm downloads Coverage Build Status DUB license semantic-release

A simple, expressive and safe Shopify / Github Pages compatible template engine in pure JavaScript. The purpose of this repo is to provide a standard Liquid implementation for the JavaScript community so that Jekyll sites, Github Pages and Shopify templates can be ported to Node.js without pain.

logo

What's it like?

Basically there're two types of Liquid syntax: tags enclosed by {% %} and outputs enclosed by {{ }}. A Liquid template looks like:

{% if username %}
  {{ username | append: ", welcome to LiquidJS!" | capitalize }}
{% endif %}

A live demo is also available and here's a quick tutorial for Liquid syntax.

Installation

Install from npm in Node.js:

npm install liquidjs

Or use the UMD bundle from jsDelivr:

<script src="https://cdn.jsdelivr.net/npm/liquidjs/dist/liquid.browser.min.js"></script>

More details, refer to The Setup Guide.

  • gulp-liquidjs: A shopify compatible Liquid template engine for Gulp using liquidjs.
  • grunt-liquify: A Grunt task to process Liquid using liquidjs. Use it to add Liquid magic to your scripts and css assets.
  • react-liquid: Liquid templating language component for React
  • @11ty/eleventy: A simpler static site generator. An alternative to Jekyll. Written in JavaScript. Transforms a directory of templates (of varying types) into HTML.

Financial Support

If you love LiquidJS or your company is using LiquidJS? Please consider support us on Open Collective or Patreon.

Backers

If you personally like LiquidJS and find it's useful to you, you can become a backer!

Sponsors

If LiquidJS is benefiting your business/company, please sponsor us to make it better!

Contributors ✨

Want to contribute? see Contribution Guidelines. Thanks goes to these wonderful people:


Jun Yang

🚧 💻

chenos

💻

Zach Leatherman

🐛

Tim Hardy

💻

Paul Robert Lloyd

💻 🐛

Alec Larson

💻

Patrick Malouin

💻 📖

jaswrks

💻

三三

💻 🤔

ssendev

💻 📖

wojtask9

💻

Andrew Barclay

💻

Cory Mawhorter

💻

Mehdi Jaffery

💻

Robin Bijlani

💻 🐛

Ryan Kennedy

💻

Sami Kukkonen

💻

Scott Santucci

💻

Steven

💡 💻

azu

📖

Joonas

💻

Jamel A.

💻

Brandon Pittman

💻

tgrandgent

💻

Martin Schuster

💻

Ray

⚠️ 💻

Cristofer Gonzales

💻

Raymond Camden

📖

Steve Stedman

📖

Anthony Ciccarello

📖

Bogdan Chadkin

💻

Tejas Manohar

💻

Peter deHaan

📖

amit777

💻 💵

Steffen Schuldenzucker

💻

Pixcell

💻

Jason Etcovitch

💻

ZC

📖

Memmie Lenglet

💻

ilhamdev0

📖

一饮一啄皆是人生

📖

Amit Agarwal

📖

Laurin Quast

💻

Matt Vague

💻

Liam Bigelow

💻

Jason Kurian

📖

d pham (they/them)

📖

Aleksandr Hovhannisyan

💻

jg-rp

💻

Ameya Apte

💻

tbdrz

📖

Santi Albo

📖

Yahang Wu

📖

Downloads/wk

165K

GitHub Stars

954

LAST COMMIT

2mos ago

MAINTAINERS

1

CONTRIBUTORS

58

OPEN ISSUES

7

OPEN PRs

1
VersionTagPublished
9.37.0
latest
2mos ago