const isIe = function () {const ua = window.navigator.userAgent;return ua.indexOf('MSIE') > -1 || ua.indexOf('Trident') > -1;};
document.documentMode. This property indicates the document compatibility mode of the document which is an integer in IE 5-11. Other browsers return undefined.const isIE = !!document.documentMode;