I have been able to make typeahead work just fine on the nav search bar, but only when invoked from the forms main menu section. If i use it from another place I am getting this console error:
Uncaught TypeError: $(...).typeahead is not a function at HTMLDocument.<anonymous> (index:967:22) at j (jquery-3.1.1.min.source.js:2:1) at k (jquery-3.1.1.min.source.js:2:1)
I am assuming that this is because a js file(typeahead.js?) is only included in the forms section of the demo and not other places, like the dashboard pages.
I am not entirely sure how to fix that though, do you have any idea ? :)
Awesome theme btw and greatly adapted for Rails, thanks!
typeahead is not a function problem (On Rails adaptation)
I have been able to make typeahead work just fine on the nav search bar, but only when invoked from the forms main menu section. If i use it from another place I am getting this console error:
Uncaught TypeError: $(...).typeahead is not a function
at HTMLDocument.<anonymous> (index:967:22)
at j (jquery-3.1.1.min.source.js:2:1)
at k (jquery-3.1.1.min.source.js:2:1)
I am assuming that this is because a js file(typeahead.js?) is only included in the forms section of the demo and not other places, like the dashboard pages.
I am not entirely sure how to fix that though, do you have any idea ? :)
Awesome theme btw and greatly adapted for Rails, thanks!
Last edited 2 years ago
//= require typehead/bootstrap3-typeahead.min.js
Yes, those third party libraries in Rails are load specified per controller.
Best, Damian