Jade Syntax does not work with pug : Node Js

user6767235

I am in a situation where I have one anchor tag in pug template: The href tag is getting its value at runtime. This code was working with Jade but as soon as I take it to pug, It stops working

a.more(href='/posts/show/#{post._id}') Read more

in the above syntax #{post._id} is suppose the bring the data at runtime but it is not working as expected.

Please help me on this.

user6767235

Just got it resolved by using the following line

 href="/posts/show/" + post._id

Its kind of weird that they stopped support for jade syntax in pug.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Meteor JS Jade template does not work as expected

From Dev

Node.js/jade syntax error: unexpected token ;

From Dev

node.js noobie trying to follow a tutorial - need to change jade reference to pug

From Dev

Jade/Pug with Angular 2 - how to resolve conflict with # syntax?

From Dev

Jade like syntax highlighting of .pug files Visual Studio 2015

From Dev

Jade/Pug with Angular 2 - how to resolve conflict with # syntax?

From Dev

Pug (Jade) syntax highlighting not working with Sublime Text 3

From Dev

Node.js and Jade

From Dev

meteor Jade iteration does not work

From Dev

Ajax with node.js/jade

From Dev

node js/jade error in css

From Dev

Block comments in Pug (Jade)?

From Dev

Import statement in jade/pug

From Dev

node express bodyparser deprecated, new syntax does not work

From Dev

node express bodyparser deprecated, new syntax does not work

From Dev

jade syntax error how to send json to js ?

From Dev

Can not make blueimp-image-gallery work with jade in node.js

From Dev

how does node.js clustering work?

From Dev

Click event in node.js does not work

From Dev

angular js is not rendering in jade (with node.js)

From Dev

Images not showing pug, express node.js

From Dev

Why --watch Jade option does not work?

From Dev

Why does this jade template not work with commenting?

From Dev

Directives scope variable does not work in Jade

From Dev

How does this JavaScript syntax bit from Ember.js work?

From Dev

React syntax does not work

From Dev

Does node.js has 'match()' method? If so what is the syntax?

From Dev

Does node.js has 'match()' method? If so what is the syntax?

From Dev

How to make the linker in Sails js work with Jade?

Related Related

HotTag

Archive