jquery.easyui.min.js:ncaught ReferenceError: jQuery is not defined
今天写项目时遇见了个很有意思的问题,使用Easyui组件是的时候运行,出现
jquery.easyui.min.js:ncaught ReferenceError: jQuery is not defined
,最后查看原因居然是引入的顺序不正确,没想到Easyui还有这种操作
正确的引入顺序
<link rel="stylesheet" type="text/css" href="jsps/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="jsps/themes/icon.css">
<script type="text/javascript" src="jsps/jquery.min.js"></script>
<script type="text/javascript" src="jsps/jquery.easyui.min.js"></script>
之前错误的引入顺序
<link rel="stylesheet" type="text/css" href="jsps/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="jsps/themes/icon.css">
<script type="text/javascript" src="jsps/jquery.easyui.min.js"></script>
<script type="text/javascript" src="jsps/jquery.min.js"></script>