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

211
Vistas
ReactJS/CSS Utilizing full page on elements

I'm not overly good with CSS, so a lot of it I'm in the process of learning. My problem at the moment is that I'm trying to get my react components to utilize the full height of the browser window. I've settled for utilizing Display: 'grid' and gridTemplateRows: '1fr' for this at the moment, but I'm having an odd effect. very start elements

As you can see above, 1FR seems to only utilize a set size, not the full page size. Down the chain after login, I will also have datagrids that need to utilize the page size, so they can resize themselves as needed... but the current issue I've run into, is that the containers aren't the size of the page, but only the size of the elements inside.

I've tried using height:'100%' in different parts, but the issue persists, as there seems to be something setting the size of the containers to not be page-size, but I've never set (as you can see in the inspector below) anything to have a hard coded height size.

UPDATED EDIT: I created Index.css for use, which contains a simple set of:

html, body {height: 100%;}
#ReactRoot {min-height: 100vh;}

I tried 2 things:

  1. in the index.html in public, and index.css in same public folder, I put to try and make it use the CSS, but it had no effect. Not sure where it is wrong in this case.

  2. in index.js, I imported index.css (same as above, but it is now in my SRC folder), via

import "./index.css";

This had this result. The top level div, ReactRoot, is fullscreen... everything inside, even with 100% height set in inline-css within the modules, does not do 100% height.

main body 100% height

however, everything further down does not seem to obey the 100% rule. Setting inline CSS in modules to height:"100%" did not have any effect

elements are not 100% height

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

0

Setting min-height to 100% will accomplish this goal.

html {
  height: 100%;
}
body {
  min-height: 100vh;
}
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