Closed ryanpag3 closed 7 years ago
ended up being an issue with my webstorm file watcher messing up the template directory and adding an .html file causing the render to fail.
@ryanpage42 glad to hear- please watch this repo and follow me on twitter if you're interested in the v3 release of this package, a complete rewrite
@niftylettuce just a quick question. Have something like this:
locals: {
name: obj.first_name + " " + obj.last_name,
token: obj.token
}
and in the template:
a.button(href='http://xyz.com/verify/#{token}', target='_blank') Activate your account
It says invalid token at #
. How do I solve this dynamically?
-a.button(href='http://xyz.com/verify/#{token}', target='_blank') Activate your account
+a.button(href=`http://xyz.com/verify/${token}`, target='_blank') Activate your account
Also try putting this above the a.button
line in your template and see what it outputs:
- console.log('token', token)
It seems token is undefined?
And see what it outputs in console
Got it working with your change itself. Thanks a ton!!
I'm trying to render a pug/jade template with node email templates.
So I pass
templateVals
to the render call, and I'm trying to figure out how to display that information on the rendered template like so:and none of these combinations seem to be working. I'm not sure what I'm doing wrong here. Thanks for your help!