jQuery UI Widgets › Forums › TreeGrid › jqxTreeGrid error on importing modules
Tagged: Angular 6, jqxButton, jqxTreeGrid, jqxwindow
This topic contains 4 replies, has 2 voices, and was last updated by smitha 6 years, 5 months ago.
-
Author
-
Hello,
I’m trying to add jqxbutton and jqxwindow so imported ButtonModule and WindowModule under app.module.ts but getting the below error,
ERROR in node_modules/jqwidgets-framework/demos/angular/app/modules/button.module.ts(4,36): error TS2307: Cannot find module ‘../../jqwidgets-ts/angular_jqxbuttons’.
node_modules/jqwidgets-framework/demos/angular/app/modules/window.module.ts(4,36): error TS2307: Cannot find module ‘../../jqwidgets-ts/angular_jqxwindow’.I’m using Angular 6 framework.
Appreciate the help!
Thank You
Hello smitha,
Could you clarify it? Which version do you use?
Because with the newer versions when you import new component for example jqxWindow you should type:
import { jqxWindowComponent } from 'jqwidgets/angular_jqxwindow';
Please, take a look at this example:
https://tseditor.com/?key=window-settingsWe recommend using the latest version of jQWidgets: http://www.jqwidgets.com/download/
Best Regards,
Hristo HristovjQWidgets team
http://www.jqwidgets.comHello Hristo,
I’m using jqwidgets-framework version – 5.7.2 and Angular 6 framework components.
If i try adding “import { WindowModule } from ‘node_modules/jqwidgets-framework/demos/angular/app/modules/window.module’;” in the app.module.ts i get the error stating “Cannot find module” but if i add “import { jqxWindowComponent } from ‘jqwidgets-framework/jqwidgets-ts/angular_jqxwindow’;” in app.module.ts it works fine.
Could you please suggest whether adding “import { jqxWindowComponent } from ‘jqwidgets-framework/jqwidgets-ts/angular_jqxwindow’;” in app.module.ts and app.component.ts is correct way of doing it?Thank You.
Hello smitha,
Yes, this is the correct approach.
It is described in our Angular tutorials:
https://www.jqwidgets.com/angular-components-documentation/documentation/angular-cli/angular-cli.htm
https://www.jqwidgets.com/angular-components-documentation/documentation/angular-cli/angular-cli-jqxgrid.htm?search=Best Regards,
Hristo HristovjQWidgets team
http://www.jqwidgets.comHello Hristo,
Thank you for the response.
After adding “import { jqxWindowComponent } from ‘jqwidgets-framework/jqwidgets-ts/angular_jqxwindow’;” in app.module.ts and app.component.ts the issue is resolved. -
AuthorPosts
You must be logged in to reply to this topic.