Skip to content

liquid

package

liquid

A port of liquid template engine for python on the shoulders of jinja2

module

liquid.utils

Some utils

Functions
  • parse_tag_args(stream, name, lineno) (Node) Parse arguments for a tag.</>
  • peek_tokens(stream, n) (list of Token) Peek ahead 'n' tokens in the token stream, but don't move the cursor</>

Provide default settings/values

Patch a couple of jinja functions to implement some featuresthat are impossible or too complex to be implemented by extensions

Including 1. Patching Parser.parse to allow 'elsif' in addition to 'elif' 2. Patching LoopContext to allow rindex and rindex0 3. Adding liquid_cycle method to LoopContext to allow cycle to have a name 4. Patching Parser.parse_for to allow arguments for tag 'for'

Functions
module

liquid.liquid

Provides Liquid class

Classes