#Nestjs not load template
5 messages · Page 1 of 1 (latest)
Where do you store your templates? What does your conifugration look like? What debugging have you done? Do you expect us to just know what your code looks like, or do you plan on actually sharing with us?
This my config in app module:
transport: {
host: 'smtp.gmail.com',
port: 587,
ignoreTLS: false,
secure: false,
auth: {
user: process.env.GMAIL_USER,
pass: process.env.GMAIL_PASS,
},
},
defaults: {
from: `"No Reply" <test.ai>`,
},
// preview: true,
template: {
dir: process.cwd() + '/src/templates',
adapter: new HandlebarsAdapter(),
options: {
strict: true,
},
},
})````
This my nest-cli.json
"$schema": "https://json.schemastore.org/nest-cli",
"collection": "@nestjs/schematics",
"sourceRoot": "src",
"compilerOptions": {
"deleteOutDir": true,
"assets": [
{ "include": "i18n/**/*", "watchAssets": true },
{
"include": "templates/**/**",
"outDir": "dist/src"
}
]
}
}
I'm check in folder dist. Template is compile, response send success