I’m using Jade to generate JST templates but I’m having trouble setting placeholder for the id field.
.somediv(id=<%= id %>)
...
Jade compiler throws an error for the above syntax
undefined:501
buf.push(attrs({ terse: true, 'id':(<%= id %>), "class": ('somediv')
Is there a way to do this?
Correct syntax for attributes seems to be:
But if you need
idto be exactly<%= id %>then you have to quote it and use!=for values that shouldn’t be escaped