• Empleos
  • Sobre nosotros
  • profesionales
    • Inicio
    • Empleos
    • Cursos y retos
  • empresas
    • Inicio
    • Publicar vacante
    • Nuestro proceso
    • Precios
    • Evaluaciones
    • Nómina
    • Blog
    • Comercial
    • Calculadora de salario

0

355
Vistas
String strings with line breaks

I am working on a portal which allow the examiner to provide a problem statement along with sample input and sample output. The issue is that when value is added to the sample input/output section it is stored as a complete string and line breaks are not getting rendered on the candidate side. Let me show you an example to make it more clear:

enter image description here

enter image description here

You can see how the line breaks doesn't get rendered on the candidate side. What changes should i make which will allow me render text properly on client side. Frontend: React Backend: Nodejs

about 3 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You can achieve desired result by using white-space: "pre-wrap".

about 3 years ago · Juan Pablo Isaza Denunciar
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 Nuestro proceso Comercial
Legal
Términos y condiciones Política de privacidad
© 2025 PeakU Inc. All Rights Reserved.

Andres GPT

Recomiéndame algunas ofertas
Necesito ayuda