Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
236 views
in Technique[技术] by (71.8m points)

Full screen height container Bootstrap

Can't get the container to stretch the full height of the screen:

<body>
    <div class="container-fluid h-100" style="background-color:#0c5460;">
        a
    </div>
</body>

I tried the h-100 and declaring height:100% and min-height:100% container-fluid and container but it never stretches beyond content that it contains

What am i missing?

enter image description here

question from:https://stackoverflow.com/questions/65944211/full-screen-height-container-bootstrap

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Need

    html,body,.container {
        height: 100%;
    }

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...