I am encountering an issue. I am working with Node.JS nodemailer.
const url = `${url}`;
var mailOptions = {
from: 'stackoverflow',
to: email,
subject: 'test',
html: 'Please click this email to confirm your email: <a href="${url}">${url}</a>`'
};
The HTML content is lengthy. Therefore, I would need to concatenate each line using
'Line1' +
'Line2' +
Unfortunately, the above lines are displaying an error indicating: align = 'center'
Is there a simple and easy way to embed this HTML file? If I can include the file separately, I have created a variable that should be displayed in HTML. How can I achieve this? Is there another method to embed the file other than directly within the code? Any assistance is appreciated!
This is my html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<!-- Rest of the HTML content goes here -->
</body>
</html>