jQWidgets Forums

jQuery UI Widgets Forums Angular Angular 2 / TypeScript

This topic contains 4 replies, has 3 voices, and was last updated by  Peter Stoev 8 years, 5 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • Angular 2 / TypeScript #86896

    Gary
    Participant

    Were do you find the jqwidgets.d.ts file?

    I “npm installed jqwidgets-framwork” and got jqwidgets 2.4.1 loaded but, not sure were the d.ts file is located.

    Do we need to generate with Typings? I did not see anything in the documentation.

    Thanks,
    Gary

    Angular 2 / TypeScript #86901

    Peter Stoev
    Keymaster

    Hi Gary,

    jQWidgets is officially available only from our website. Other packages on internet in the most usual case are not built from us and our team. Our jQWidgets 4.2.1 version with Angular 2 components and Typescript definitions can be found only on our website’s download page. Angular 2 and Typescript are added to a new folder, which we called jqwidgets-ts. Our online demos use Typescript 1.8.10 and Angular 2 RC 5.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    Angular 2 / TypeScript #86925

    Gary
    Participant

    Thanks Peter….

    Angular 2 / TypeScript #89357

    junior
    Participant

    Hello Peter Stoev,

    I’m asking why your angular 2 component widgets are still using the old jquery-1.11.1.min.js, in fact there is a new release version of jquery which is 3.1.1? If I’m going to use the latest release of jquery instead of the old one can I still able to run the widgets under angular 2?

    Another question I have a problem with assigning the returned query using subscription.

    items: any[] ;
    this.dataService.getBeverages()
    .subscribe((data) => {
    this.items.push(data);
    });

    // prepare the data
    source =
    {
    datatype: “json”,
    datafields: [
    { name: ‘id’ },
    { name: ‘parentid’ },
    { name: ‘description’ }

    ],
    id: ‘id’,
    localdata: this.items <– The problem is here i cannot assigned values, so when I call the getRecordHierarchy method records is empty.
    Thanks.

    Angular 2 / TypeScript #89361

    Peter Stoev
    Keymaster

    Hi junior,

    jQuery version does not matter. You can use the version which you prefer. getRecordHierarchy requires this.items to be full with items. I guess that your items are pushed asynchronously and that is the issue in your case.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.