I have an object like this:
foo = {"Foo Bar":"bar","Foo":"Bar"};
In my Jade template I have:
p 1: {{foo.Foo Bar}}
p 2: {{foo.Foo}}
Problem is, the output is:
1: {{foo.Foo Bar}}
2: Bar
But it should be:
1: bar
2: Bar
Why is this problem happening? How do I fix this?
You can access it like this
p 1: {{foo["Foo Bar"]}}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With