How to use JQuery-UI with Aurelia

前端 未结 2 1300
野的像风
野的像风 2021-01-12 04:31

I started a new Aurelia app using the Aurelia CLI.

I installed JQuery and configured aurelia.json using the instructions at the Aurelia documentation:

http:/

2条回答
  •  逝去的感伤
    2021-01-12 05:15

    I'm using Aurelia 1.0.X, after updating I needed these two imports for using any jQuery-UI widget, in this case draggable. It also works when importing slider or resizable.

    import $ from 'jquery';
    import {draggable} from 'jquery-ui';
    

    In my package.json, my jspm dependencies are as follows:

    "jquery": "npm:jquery@^3.2.1",
    "jquery-ui": "github:components/jqueryui@^1.12.1"
    

提交回复
热议问题