Skip to content

Instantly share code, notes, and snippets.

@zearadoua
Created July 2, 2018 15:46
Show Gist options
  • Save zearadoua/887617f8ee38e16ca0271ccb3a6a168a to your computer and use it in GitHub Desktop.
Save zearadoua/887617f8ee38e16ca0271ccb3a6a168a to your computer and use it in GitHub Desktop.
detect safari browser
(function($){
"use strict";
if ( /^((?!chrome|android).)*safari/i.test(navigator.userAgent)) {
$("html").addClass("safari-detected");
}
})(jQuery);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment