harttle / liquidjs

A simple, expressive, safe and Shopify compatible template engine in pure JavaScript.
https://liquidjs.com
MIT License
1.52k stars 238 forks source link

Adds support for options to CLI and improves usability #586

Closed DaRosenberg closed 1 year ago

DaRosenberg commented 1 year ago

This PR adds the following improvements to the CLI experience:

The --template option is necessary to distinguish legacy mode, but can be removed in favor of a nameless argument for version 11.0, so the syntax would become for example:

npx liquidjs 'Hello, {{ name }}!' --context '{"name": "Snake"}' --js-truthy

Fixes #583 Fixes #584 Fixes #585

DaRosenberg commented 1 year ago

@harttle Any idea when you might get a chance to either merge this one, or let me know if further changes are required?

Reason I ask is, we need this functionality, and if it will take several weeks to get it into a release, then I think we may need to think about publishing our own wrapper package for this instead.

github-actions[bot] commented 1 year ago

:tada: This PR is included in version 10.5.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: