Get the App
SLTechnology News&Howtos  ›  Development  › 

How to set the height of vue single page to 100% full screen

Shulou Source: shulou.com Published: 2022-05-31 22:41:23 10月01日 Update

This article introduces the knowledge of "how to set the height of vue single page to 100% full screen". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

Single page setting height 100% full screen

Most of the time, we set the height of a single page to 100% and never get a full screen.

The height of the effect picture is supported by the content.

The solution is simple.

Create a css

Html, body, # app {height: 100%; margin: 0; padding: 0;}

Then introduce the global (into min.js)

Now let's see the effect.

The height setting is 100% invalid

Scenario: when a single page requires operations such as filling colors of the entire page, and the page height is required to be the screen height, setting height:100% is invalid.

Solution: set height: 100% in App.vue

/ / App.vuehtml,body,#app {height:100%;} "how to set the height 100% full screen for a single vue page" ends here. Thank you for your reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Tags: Height page content effect more knowledge practicality achievement next overall situation dilemma scene reality screen situation effect drawing article method time case Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker vpn MariaDB Microsoft Linux