Search code examples
javascriptjqueryember.jsember-cli

jQuery UI with Ember CLI


So I'm pretty much having the exact problem listed here: Using jquery in Ember-cli

But I've already done the following as recommended in the thread above:

Added:

app.import('bower_components/jquery-ui/jquery-ui.js');
app.import('bower_components/jquery-ui/ui/tooltip.js');

Changed

Ember.$(selector).tooltip();

to

this.$(selector).tooltip();

Ember isn't recognizing the tooltip function as being defined despite UI being installed and doing the above.

Error:

Uncaught TypeError: undefined is not a function

Any help?


Solution

  • The problem was I had imported Ember Data which was causing an error (apparently it's imported by default or the options were stated incorrectly). Once I removed that, UI is now working properly.

    Thank you for all your help Sam!