DaftMonk / angular-tour

AngularJS directive for giving an interactive tour of your website.
http://daftmonk.github.io/angular-tour/
MIT License
609 stars 137 forks source link

Getting "undefined is not a function" error messages #9

Closed GillesDebunne closed 9 years ago

GillesDebunne commented 10 years ago

I installed and copy pasted the sample code in my project (jquery 2.1.1, angular 1.2.16). I get "undefined is not a function" error messages in the console, for the 'hide' and 'show' methods, where 'detach()' and 'fadein()' are applied to the tourtip variable. This var is the result of a $compile defined above, and is indeed non null.

I didn't investigate any further, and the error may well be on my side. Just in case others bump into the same issue.

mherrema commented 10 years ago

I'm experiencing this as well. Any solution?

mherrema commented 10 years ago

Found that when jquery must be included before angular in the html, and the tour will work as intended. Experienced problems with angular objects, but after updating to the latest version of angular, everything works!

kumarharsh commented 10 years ago

That would surely be the case. Angularjs would use the inbuilt jqlite if it doesn't find jQuery before it loads. Therefore, the hide() and show() methods won't be there on angular.element, as documented here

booleanbetrayal commented 9 years ago

There's an open PR (#21) for removing the jQuery dependencies entirely. Going to go ahead and close this and will update the docs.