我有一個使用 bootstrap 和 jQuery 的專案,當我輸入導航代碼時,它在控制臺中給了我這個錯誤:
bootstrap.min.js:6 Uncaught TypeError: i.createPopper is not a function
at xt._createPopper (bootstrap.min.js:6:23887)
at xt.show (bootstrap.min.js:6:22196)
at xt.toggle (bootstrap.min.js:6:22024)
at HTMLAnchorElement.<anonymous> (bootstrap.min.js:6:26602)
at HTMLDocument.s (bootstrap.min.js:6:4510) :
我正在嘗試使用 jQuery 版本:2.2.1 和 1.12.4。
uj5u.com熱心網友回復:
您可能缺少專案中的 popper.js。使用下面的 CDN 添加它:
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js" integrity="sha384-ApNbgh9B Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script>
如果您想在一個腳本呼叫中包含這兩個檔案,請參閱Bootstrap 4的檔案。
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/486263.html
下一篇:如何定位MySQL資料行
