Cannot use angular-summernote function summarnote undefined
I am using Summernote Angular. However, for some reason it doesn't work.
Problem:
Unable to define summarnote function ...
<summernote code="text"></summernote>
<script src="components/bower_components/summernote/dist/summernote.js"></script>
<script src="components/bower_components/angular-summernote/src/angular-summernote.js"></script>
ypeError: undefined is not a function
at activate (http://localhost/tm/app/components/bower_components/angular-summernote/src/angular-summernote.js:57:15)
at link (http://localhost/tm/app/components/bower_components/angular-summernote/src/angular-summernote.js:129:30)
at http://localhost/tm/Scripts/angular.js:7113:44
at nodeLinkFn (http://localhost/tm/Scripts/angular.js:6711:13)
at compositeLinkFn (http://localhost/tm/Scripts/angular.js:6105:13)
at compositeLinkFn (http://localhost/tm/Scripts/angular.js:6108:13)
at nodeLinkFn (http://localhost/tm/Scripts/angular.js:6705:24)
at compositeLinkFn (http://localhost/tm/Scripts/angular.js:6105:13)
at publicLinkFn (http://localhost/tm/Scripts/angular.js:6001:30)
at link (http://localhost/tm/Scripts/angular-route.js:918:7) <div class="summernote ng-isolate-scope" code="text"> angular.js:10071
I am currently using the following directive: https://github.com/outsideris/angular-summernote/blob/master/src/angular-summernote.js
You can suggest a better alternative if this is not the right solution.
I've also tried:
<script src="components/bower_components/angular/angular.js"></script>
<script src="components/bower_components/summernote/dist/summernote.js"></script>
<script src="components/bower_components/angular-summernote/dist/angular-summernote.min.js"></script>
+3
source to share
2 answers
This worked for me, it might work for you too:
changes:
<script src="components/bower_components/summernote/dist/summernote.js"></script>
<script src="components/bower_components/angular-summernote/src/angular-summernote.js"></script>
in
<script src="components/bower_components/summernote/dist/summernote.js"></script>
<script src="components/bower_components/angular-summernote/dist/angular-summernote.min.js">
The exact flow worked:
bower install summernote
bower install angular-summernote
and then:
<script src="components/bower_components/summernote/dist/summernote.js"></script>
<script src="components/bower_components/angular-summernote/dist/angular-summernote.min.js">
+4
source to share
You have to include jquery and bootstrap like:
<script src="components/jquery/dist/jquery.min.js"></script>
<script src="components/bootstrap/dist/js/bootstrap.min.js"></script>
send an example . These are dependent values ββ<β
And I am an angular-summernote author.
+3
source to share