I have 2 menus as symbols in a example below:
The menu on the left is mobileNav and right is deskNav. I have this for 'Composition Ready':
$(window).resize(function() {
if ($(window).width() <= 799) {
//alert('Less than 799');
sym.$("deskNav").css("visibility","hidden");
sym.$("mobileNav").css("visibility","visible");
}
else {
//alert('More than 799');
sym.$("deskNav").css("visibility","visible");
sym.$("mobileNav").css("visibility","hidden");
}
});
But they both show up regardless of how big my browser window is upon preview. Until I flex the browser, either the mobileNav or deskNav will become hidden.
Is there any way to make sure if the browser is a certain size that it doesn't appear at all upon loading?