Vue gets body height

the vue sub-component is a pop-up box, which has a mask layer, but the mask layer can only cover the height of the screen, not the excess document height.

this.$el.clientHeight

if you use the above syntax in mouted, you can only get the screen height.
excuse me: how to find the body height after rendering after the background obtains the data

Oct.21,2021

you can try to hang id on body , and then use dom to get


document.body.offsetHeight


css fixed layout. You don't need js. If you can solve it with css, you can never use js


agree to the third floor. Wow, position:fixed. Set overflow:hidden to hide the excess. In this way, the elements in the mask can be easily centered up and down.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3bbbc-2c2b3.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3bbbc-2c2b3.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?