Is there a way to tell if a visitor is visiting from mobile/tablet or from desktop?

I want to re-direct a user out of a page if they’re visiting from their phone or tablet. Is there some sort of function that returns this information? I’m imaging something like this:

if( isMobile() === true) {
    wixLocation.to("/redirect-page")
}

(I’ve poured through Corvid documentation for this but can’t find anything. If someone knows a workaround, it would be greatly appreciated!)

Hi Kevin,

There is a way:
https://www.wix.com/corvid/reference/wix-window.html#formFactor

Awesome, thank you so much Anthony!