I'm tying to wrote script to detect mobile browsers that not supports css 100vh value:
var is_android = ((nua.indexOf('Mozilla/5.0') > -1 && nua.indexOf('Android ') > -1 && nua.indexOf('AppleWebKit') > -1) && !(nua.indexOf('Chrome') > -1)); if (is_android) { document.write('<link rel="stylesheet" type="text/css" href="moz5.css">'); } else { document.write('<link rel="stylesheet" type="text/css" href="maxi.css">'); } this code should target android native browser, but is targetting IE mobile too.
Is better JS way to target mobile browsers or all browsers that arent supporting css 100vh and 100vw value?