I've post the solution down below. I'm open to suggestions on how to improve though, so, please don't hesitate to suggest a better way!
I'm using Aurelia CLI for my web-app. I'm trying to use jQuery tabs and jQuery datepicker, but nothing works
I've got a demo on gitHub here where all you have to do is clone, then run
npm install; au run
I'm using the example provided in this StackOverflow question How to use JQuery UI components in Aurelia getting started app (navigation app)
If you look in src/routes/tabs you'll see I'm including I'm including jQuery by using
import $ from 'jquery';
import {tabs} from 'jquery-ui';
In my aurelia.json
, I'm including jquery and jquery-ui via the lines
"dependencies": [
"jquery",
"jquery-ui"
]
If I change the the import to
"jquery",
{
"name": "jquery-ui",
"path": "../node_modules/jquery-ui",
"main": "jquery-ui"
"deps": ["jquery"],
"exports": "$"
}
I still get no error. The code just does nothing.
I suspect the root cause is a configuration issue, but any help would be super appreciated!