Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

285
Vistas
Handlebars missing style when sending email

I have a node server that is sending emails templates.
When I'm opening that template locally it runs the CSS styles as properly at is should.
When I'm sending this as an a email to myself for testing some CSS doesn't apply.

CSS being received from a test email:

mainCon {
  width: 936px;
  background-color: #e9e9e9;
  display: flex;
  font-size: 24px;
  border-radius: 0px 0px 20px 20px;
}

Original full CSS:

mainCon {
  width: 936px;
  height: max-content;
  background-color: #E9E9E9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  border-radius: 0px 0px 20px 20px;
}

Server (nodemailer):

const mailOptions = {
  from: "email@yahoo.com",
  to: "email@yahoo.com",
  subject: `sub`,
  template:'index',
  context: {
    fullName: req.body.fullName,
    reason: req.body.reason,
    problem: req.body.problem,
  }
}

The CSS is inside the handlebars style component attached to the head

handlebars html code

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div class="mainCon">
        <p class="title">title</p>
        <div class="nameNreasonCon">
            <div class="reasonCon">
                <p>{{reason}}</p>
            </div>
            <div class="nameCon">
                <p>{{fullName}}</p>
            </div>
        </div>
        <div class="problemCon">
            <p>{{problem}}</p>
        </div>
    </div>
</body>
</html>
over 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda