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

158
Vistas
My output refused to change after i changed the code in the ReactDOM.render() method in my index.js file

After running the npx create-react-app my-app, cd my-app, npm start. It launched a browser on localhost:3000. After which I opened the index.js file the ReactDOM.render() method read

ReactDOM.render(
<React.StrictMode>
<App />
</React.StrictMode>
document.getElementById('root')
);
ReactDOM.render(
<h1> Hello, React! </h1>
document.getElementById('root')
);

The output is supposed to show Hello, React!. instead its showing the output from app.js. please I want my output to read "Hello React!"

about 4 years ago · Juan Pablo Isaza
2 Respuestas
Responde la pregunta

0

Remove the first render... You have 2 render... Js runs from top to bottom, so it's rendering the first one

about 4 years ago · Juan Pablo Isaza Denunciar

0

You have two ReactDOM.render, remove the first one with the component.

You will be left with this code:

ReactDOM.render(<h1> Hello, React! </h1>, document.getElementById('root'));

It should work like this.

about 4 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 Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda