yads / nodemailer-express-handlebars

A plugin for nodemailer that uses express-handlebars view engine to generate emails
87 stars 30 forks source link

can't render array of objects #65

Closed marksaado closed 2 months ago

marksaado commented 1 year ago

Hello there,

I'm trying to loop array of objects called reservation_items, this is my code: {{#each reservation_items}}

Item ID: {{this.itemId}} Quantity: {{this.value}} Item Price: {{this.itemPrice}} Item Name: {{this.name}}

  {{/each}}
yads commented 2 months ago

Not really sure I can help. This package simply uses express-handlebars to generate the html, it doesn't do any processing of templates directly. This is likely an issue with your template, what's in reservation_items, or an issue with express-handlebars package