diff --git a/README.md b/README.md index 1b1511e6d..55987346a 100644 --- a/README.md +++ b/README.md @@ -15,12 +15,25 @@ A simple, expressive and safe [Shopify][shopify/liquid] / Github Pages compatibl
+## What's it like? + +Basically there're two types of Liquid syntax: tags enclosed by `{% %}` and outputs enclosed by `{{ }}`. A Liquid template looks like: + +```liquid +{% if username %} + {{ username | append: ", welcome to LiquidJS!" | capitalize }} +{% endif %} +``` + +[A live demo](https://liquidjs.com/playground.html) is also available and here's a [quick tutorial](https://liquidjs.com/tutorials/intro-to-liquid.html) for Liquid syntax. + + ## Installation Install from npm in Node.js: ```bash -npm install --save liquidjs +npm install liquidjs ``` Or use the UMD bundle from jsDelivr: diff --git a/docs/source/_data/menu.yml b/docs/source/_data/menu.yml index 456e63797..d3caab19c 100644 --- a/docs/source/_data/menu.yml +++ b/docs/source/_data/menu.yml @@ -1,4 +1,4 @@ -tutorials: /tutorials/setup.html +tutorials: /tutorials/intro-to-liquid.html tags: /tags/overview.html filters: /filters/overview.html playground: /playground.html diff --git a/docs/source/tutorials/contribution-guidelines.md b/docs/source/tutorials/contribution-guidelines.md index 4d730acc5..3d362a739 100644 --- a/docs/source/tutorials/contribution-guidelines.md +++ b/docs/source/tutorials/contribution-guidelines.md @@ -26,7 +26,7 @@ npm test ## Financial Support -LiquidJS is Open Source and Free and **without** capitalists support and **without** any ADs. To help it live and thrive, consider contribute on [Open Collective][oc] or [Patreon][pt]. To acknowledge your contribution, your name and avatar will be listed here and on [Github README][liquidjs]. +LiquidJS is Open Source and Free. To help it live and thrive, please consider contribute on [Open Collective][oc] or [Patreon][pt]. To acknowledge your contribution, your name and avatar will be listed here, [homepage](https://liquidjs.com/) for LiquidJS and on [Github README][liquidjs]. diff --git a/docs/source/tutorials/intro-to-liquid.md b/docs/source/tutorials/intro-to-liquid.md index 3d52aef63..82c9e9874 100644 --- a/docs/source/tutorials/intro-to-liquid.md +++ b/docs/source/tutorials/intro-to-liquid.md @@ -1,5 +1,5 @@ --- -title: Introduction to Liquid Template Language +title: The Liquid Template Language --- LiquidJS is a simple, expressive and safe [Shopify][shopify/liquid] / Github Pages compatible template engine in pure JavaScript. The purpose of this repo is to provide a standard Liquid implementation for the JavaScript community. Liquid is originally implemented in Ruby and used by Github Pages, Jekyll and Shopify, see [Differences with Shopify/liquid][diff]. @@ -9,6 +9,10 @@ LiquidJS syntax is relatively simple. There're 2 types of markups in LiquidJS: - **Tags**. A tag consists of a tag name and optional arguments wrapped between `{%raw%}{%{%endraw%}` and `%}`. - **Outputs**. An output consists of a value and a list of filters, which is optional, wrapped between `{%raw%}{{{%endraw%}` and `}}`. +{% note info Live Demo %} +Before going into the details, here's a live demo to play around: