How to import DevExpress.data.CustomStore ?
See original GitHub issueHow to import DevExpress.data.CustomStore
into TypeScript?
The only place I found this declaration is in devextreme/dist/ts/dx.all.d.ts
. However, when I try
import { CustomStore } from 'devextreme/dist/ts/dx.all';
it doesn’t work. It gives: [ts] File 'devextreme/dist/ts/dx.all.d.ts' is not a module.
– which is comprehensible, since there isn’t a dx.all.js
in this same folder.
For the sake of completion: I’m trying to port this code from Angular 1.5:
this.gridDataStore = new DevExpress.data.CustomStore({
load: (loadOptions) => $q.resolve(this.getBuffer(loadOptions.skip, loadOptions.skip + loadOptions.take)),
totalCount: () => $q.resolve(this.data.length),
update: (key, values) => { this.data[key.a] = values.c; return $q.resolve(values); }
});
Using “devextreme-angular2”: “^16.1.7” “typescript”: “2.0.3”
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
CustomStore - DataSource - DevExtreme - DevExpress
The CustomStore enables you to implement custom data access logic for consuming data from any source. Included in: dx.web.js, dx.viz.js, dx.all.js. import ......
Read more >JavaScript Custom Store Configuration - DevExtreme
var store = new DevExpress.data. ... import CustomStore from 'devextreme/data/custom_store';; import DataSource from 'devextreme/data/data_source'; ...
Read more >Use CustomStore: DevExtreme - JavaScript UI Components ...
Custom Store is a Store that allows you to connect a UI component to a web service with its own data accessing logic....
Read more >Custom Data Sources - DevExtreme - DevExpress
DevExtreme provides the CustomStore component to load and edit data from any data ... import React from 'react';; import 'devextreme/dist/css/dx.light.css'; ...
Read more >Documentation: DevExtreme - JavaScript Custom Store Methods
import CustomStore from "devextreme/data/custom_store";; import DevExpress from "devextreme/bundles/dx.all"; ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You can do this in version 16.2. Recently, we published an alpha version of 16.2:
16.2.1-alpha.1
. With this version, you can declare CustomStore like this:GH165.zip
@fdcastel I think you are getting the
Cannot find name 'DevExpress'
error when tsc compiles our component. To resolve the issue, declare DevExpress in the following way:declare let DevExpress: any;
GH165.zip