From: Marius Gavrilescu Date: Wed, 8 Apr 2015 17:59:05 +0000 (+0300) Subject: Use window.innerWidth instead of document.body.clientWidth X-Git-Url: http://git.ieval.ro/?p=plack-app-gruntmaster.git;a=commitdiff_plain;h=a7e836f27d8959ad676632e859f7e9ad79595de8 Use window.innerWidth instead of document.body.clientWidth --- diff --git a/js/90-mobilenav.js b/js/90-mobilenav.js index ad354ac..f877421 100644 --- a/js/90-mobilenav.js +++ b/js/90-mobilenav.js @@ -2,7 +2,7 @@ 'use strict'; $( document ).ready(function(){ - if(document.body.clientWidth >= 768) + if(window.innerWidth >= 768) return; $('#title').before('
Tap title to toggle menu
'); $('nav').addClass('hidden');