I want to write my pug array in multiple lines like this:
- var data = [
["1", "1.1"],
"2"
]
but pug doesnt allow it. I have to write it inline like this atm:
- var data = [["1", "1.1"], "2"]
Any idea? Thanks for help.
I want to write my pug array in multiple lines like this:
- var data = [
["1", "1.1"],
"2"
]
but pug doesnt allow it. I have to write it inline like this atm:
- var data = [["1", "1.1"], "2"]
Any idea? Thanks for help.
Share Improve this question asked Jan 17, 2017 at 0:08 phngphng 3523 silver badges13 bronze badges 1- Or how can I realise this? To work with an json object would be much more comfortable? naltatis.github.io/jade-syntax-docs/#variables – phng Commented Jan 17, 2017 at 0:11
1 Answer
Reset to default 22As suggested in https://github.com/pugjs/pug/issues/502#issuecomment-137893041
try this:
-
var data = [
["1", "1.1"],
"2"
]
Note that the -
is on a separate line.