Last active
February 8, 2017 16:49
-
-
Save brunorios1/dd78c1e17cd420785e8e to your computer and use it in GitHub Desktop.
[js] check if Modernizr is loaded, detect a feature and run code
This file contains hidden or 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
| if (typeof Modernizr == 'object') { | |
| if (!Modernizr.touch) { | |
| console.log('Touch device'); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment