Created
February 12, 2016 22:30
-
-
Save robmadole/40c906eb75e34b200457 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//= require "domready" | |
(function () { | |
domready(function () { | |
var bns; | |
var supported = (function () { | |
var checks = []; | |
try { | |
if (!Object.keys || !Array.prototype.map) { | |
return false; | |
} | |
checks = Object.keys(Modernizr).map(function (check) { | |
return !!Modernizr[check]; | |
}); | |
return !~checks.indexOf(false); | |
} catch(e) { | |
return false; | |
} | |
})(); | |
if (!supported) { | |
bns = document.getElementById('browser-not-supported'); | |
bns.className = bns.className + ' show'; | |
} | |
window.BROWSER_SUPPORTED = supported; | |
}); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment