nuxt-modules / device

Nuxt module for detecting device type.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How does refreshOnResize work?

IamRaduB opened this issue · comments

Perhaps I misunderstood what refreshOnResize does, but it seems that it just populates the flags again, only taking into account the user agent. The user agent does not change when you resize the browser window or rotate the mobile device, so I dont understand what its purpose is.

Oh, I have the same question. If I open devtools, everything breaks at once.

commented

same, my v-if / v-else doesn't work with refreshOnResize option

The option is the solution for a problem mentioned in the following issue.
#60 (comment)

The option is the solution for a problem mentioned in the following issue. #60 (comment)

hi, i saw this problem and read the comments. But the Resize option still doesn't work((

commented

The option is the solution for a problem mentioned in the following issue. #60 (comment)

hi, i saw this problem and read the comments. But the Resize option still doesn't work((

You can use the device-type plugin for SSR checks. To check the resize in the browser, you can use the resize event listener + window.innerWidth and additionally check the device type via $device if required.