hasura / kriti-lang

A minimal JSON templating language
Apache License 2.0
56 stars 9 forks source link

Feature/escape uri function #22

Closed solomon-b closed 3 years ago

solomon-b commented 3 years ago

Adds an escapeUri primitive function, fixes operators in if statements, and removes operators outside of if statements.

The URI escape primitive is needed to make string interpolation usable with interpolating URIs.

We need decided about the syntax for operators outside of if statements. Should they require double curly brackets or not? For the time being {{ if 1 > 0 }} true {{ else }} false ] }} can be used in place of 1 > 0.

jkachmar commented 3 years ago
  • adds an escapeUri primitive function
  • fixes operators in if statements
  • removes operators outside of if statements

IMO these should be three separate PRs, unless you think there's some common thread that links all three of these components together.