Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

123
Visualizações
Custom HTML within React MUI tags

I'm currently working on a personal portfolio website where I will be inputting various work experiences, portfolio entries and the like.

In the description of these experiences I would like to have some freedom in the formatting. For example, I might want to add a list in the description. Or I'd like to be able to bold, or italicize different elements in the description.

I'm currently rendering each entry using the map function, and inserting HTML tags in the description just renders the tags in plaintext.

{myExperiences.map((experience) => (
    <CardContent sx={{ flexGrow: 1 }}>
        <Typography gutterBottom variant="h5" component="h2">
            {experience.name}
        </Typography>
        <Typography gutterBottom component="h2">
            {experience.title}
        </Typography>
        <Typography>
            {experience.description} {/* Custom formatting for some entries here */}
        </Typography>
        <Typography sx={{ color: "gray" }}>
            {experience.startDate} - {experience.endDate}
        </Typography>
        <Typography sx={{ color: "gray" }}>
            {experience.location}
        </Typography>
    </CardContent>
))}

What would be a good way to add custom formatting for certain entries? Ideally the custom formatting shouldn't interfere too much with the rest of the code, however I'm not sure how I'd be able to implement it in a standardized way like this. The formatted descriptions should also be able to be placed in a database

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda