jquery mobile Cannot set property 'mobile' of undefined

使用 jquery mobile出现错误。

Uncaught TypeError: Cannot set property 'mobile' of undefined
    at jquery.mobile-1.4.5.js:26
    at jquery.mobile-1.4.5.js:26
    at jquery.mobile-1.4.5.js:22
    at jquery.mobile-1.4.5.js:22

原来加载需要是有顺序的:jquery包在上面。

必须在导入jquery.mobile-1.4.5.min.js之前
导入jquery-1.11.3.min.js,
否则影响浏览器对jquery的使用。
<script src="js/jquery-1.11.3.min.js"></script>
<script src="js/jquery.mobile-1.4.5.js"></script>

 

posted @ 2020-06-06 03:34  假程序猿  阅读(471)  评论(0)    收藏  举报