使用最新版jquery出现Cannot read property ‘msie’ of undefined报错

有两个解决方法,要么使用jquery-migrate.js要么使用如下代码

jQuery.browser = {};
(function() { jQuery.browser.msie = false;
jQuery.browser.version = 0; if (navigator.userAgent.match(/MSIE ([0-9]+)./)) { jQuery.browser.msie = true;
jQuery.browser.version = RegExp.$1; } })();
评论
:broken_heart: :confounded: :flushed: :frowning: :grinning: :heart: :kissing_heart: :mask: :pensive: :rage: :relaxed: :scream: :smile: :smirk: :sob: :stuck_out_tongue_closed_eyes: :stuck_out_tongue_winking_eye: :wink: