fix: braced property access

This commit is contained in:
wyozi
2020-10-09 21:18:40 +08:00
committed by Jun Yang
parent a6126c3bea
commit 18a807ea2e
4 changed files with 24 additions and 2 deletions
+5
View File
@@ -18,4 +18,9 @@ describe('Issues', function () {
const html = await engine.parseAndRender(template)
expect(html).to.equal('foo')
})
it('#259 complex property access with braces is not supported', async () => {
const engine = new Liquid()
const html = engine.parseAndRenderSync('{{ ["complex key"] }}', { 'complex key': 'foo' })
expect(html).to.equal('foo')
})
})