How to detect a particular feature through JavaScript with HTML

JavascriptWeb DevelopmentFront End Scripts

Use Modernizr in HTML to detect a feature like audio through JavaScript:

if (Modernizr.audio) {
   /* properties for browsers that
   support audio */
} else{
   /* properties for browsers that
   does not support audio */
}
raja
Published on 11-Apr-2018 09:40:57
Advertisements