I have this fragment of code in nodejs
app.get('/consul', function(req, res, next) {
//
res.render('c_pUser', { title: conUsers});
});
the title variable I want to pass it to javascript on the client side
try to show it in javascript on the client side like this:
var nuevaVariable=<%=title%>;
alert(nuevaVariable);
but I get an error
How can I pass the nodejs variable to javascript on the client side?