我們正在使用angular製作一個新項目。該項目首先使用bootstrap和jquery進行設計。現在我們演變爲AngularJS,而不僅僅是php和jquery。但幾乎jQuery中的每個插件都無法使用angular,這是Summernote發生的事情。無法使jQuery Summernote與angularJS一起工作,它根本不顯示
我嘗試複製索引內,並在頁面內,但它不起作用。嘗試了很多東西,但仍然無法正常工作。
我在做什麼:這裏是我的JS在我的主模板鏈接:
<!-- jQuery first, then Bootstrap JS. -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>
<script src="framework/js/bootstrap.min.js"></script>
<script src="libs/jquery-validate/jquery.validate.min.js"></script>
<!-- Angularjs first, then directives and angularJS app. -->
<script src="https://code.angularjs.org/1.3.18/angular.min.js"></script>
<script src="https://code.angularjs.org/1.3.18/angular-resource.min.js"></script>
<script src="https://code.angularjs.org/1.3.18/angular-cookies.min.js"></script>
<script src="libs/angularjs-ui-router/angular-ui-router.min.js"></script>
<script src="libs/angularjs-validate/angular-validate.min.js"></script>
<script src="app/js/protected.js"></script>
<script src="app/js/service.js"></script>
<script src="app/js/app.js"></script>
<!-- Script and Setups for all pages -->
<script src="js/ie10-viewport-bug-workaround.js"></script>
<script src="js/main.js"></script>
<!-- Assets and libraries -->
<!--summernote-->
<script src="assets/summernote/dist/summernote.min.js"></script>
<script src="assets/summernote/dist/lang/summernote-es-ES.js"></script>
<!-- Match Height -->
<script src="assets/jquery-matchheight/jquery.matchheight.js"></script>
然後我tryed調用它這樣,
jQuery(document).ready(function() {
$('.summernote').summernote({
height: 300, // set editor height
minHeight: null, // set minimum height of editor
maxHeight: null, // set maximum height of editor
focus: false // set focus to editable area after initializing summernote
}); });
我在做什麼錯?,我不知道如何使用角度版本,或者如何整合這個。
任何線索或幫助將graet。
你必須添加之前參考angularjs的jQuery的腳本參考 –