Vue gets body height

problem description

how do I get the body height of vue after loading data?

the environmental background of the problems and what methods you have tried

for a web page embedded in app, ios needs to get the height of the page.

related codes

mounted(){
            console.log(document.body.scrollHeight)
        },

what result do you expect? What is the error message actually seen?

is not available in the mounted hook.
how to get the body height of loaded data?

Feb.22,2022

if you want to listen to the data loading completion on the home page, you can listen to the list, in watch and then:

this.$nextTick(() => {
    const height = document.body.scrollHeight
})
Menu