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

How to get a list of variable names used in a template. #571

Closed amit777 closed 1 year ago

amit777 commented 1 year ago

Is it possible to get an array of variable names that are used in a template after parsing the template?

We needed to do this for some error checking conditions, but I wasn't sure how easy it would be.

harttle commented 1 year ago

Please see this discussion https://github.com/harttle/liquidjs/discussions/528