Skip to content

Conversation

imarkkinen
Copy link

@imarkkinen imarkkinen commented Sep 15, 2024

Fixes #543

let parser = liquid::ParserBuilder::with_stdlib().build().unwrap();
let tpl = parser.parse("{{['other']}}").unwrap();
let globals = liquid::object!({
        "my": {"variable": "value"}, "other": "other_value"
     });
 let res = tpl.render(&globals).unwrap();
// "other_value"

Currently the above fails as it's not considered valid liquid markup in liquid-rust.

  • Tests created for any new feature or regression tests for bugfixes.

@imarkkinen imarkkinen marked this pull request as ready for review September 15, 2024 08:26
@imarkkinen imarkkinen changed the title Allow accessing the root value with index without a preceding identifier Allow accessing the globals with index without a preceding identifier Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Index access to globals produces parse error
1 participant