Skip to content

Instantly share code, notes, and snippets.

View kofrimpong's full-sized avatar

K. O. Frimpong kofrimpong

View GitHub Profile
@kofrimpong
kofrimpong / AzureADAuthProvider.ts
Created June 13, 2020 15:45
Microsoft Authentication Library (MSAL) for JS
import { UserAgentApplication, Logger, LogLevel } from "msal";
export const isIE = () => {
const ua = window.navigator.userAgent;
const msie = ua.indexOf("MSIE ") > -1;
const msie11 = ua.indexOf("Trident/") > -1;
// If you as a developer are testing using Edge InPrivate mode, please add "isEdge" to the if check
// const isEdge = ua.indexOf("Edge/") > -1;