I am new to wix coding but I want to manually redirect to wix’s mobile site layout on specific width.
I have a code there looks like this, but it doesn’t work
import wixWindow from 'wix-window';
$w.onReady(function () {
} );
wixWindow.getBoundingRect()
.then( (windowSizeInfo) => {
let windowWidth = windowSizeInfo.window.width;
if (windowWidth <= 600) {
wixWindow.formFactor === "Mobile"
}
} );
Anyone who can help with this?