// CHECKS IF USER IS ON DESKTOP if (screen.width > 768) { location.href = '/'; }