DevExtreme Angular - LocalStore Properties
errorHandler
Type:
This function accepts a JavaScript Error object as the parameter.
TypeScript
- import LocalStore from "devextreme/data/local_store";
- // ...
- export class AppComponent {
- store: LocalStore;
- constructor() {
- this.store = new LocalStore({
- // ...
- errorHandler: function (error) {
- console.log(error.message);
- }
- })
- }
- }
flushInterval
Specifies a delay in milliseconds between when data changes and the moment these changes are saved in the local storage. Applies only if immediate is false.
Type:
Default Value: 10000
key
In the following example, the ProductID
and ProductCode
properties are specified as key properties:
TypeScript
- import LocalStore from "devextreme/data/local_store";
- // ...
- export class AppComponent {
- store: LocalStore;
- constructor() {
- this.store = new LocalStore({
- // ...
- key: ["ProductID", "ProductCode"]
- })
- }
- }
name
Specifies the name under which data should be saved in the local storage. The dx-data-localStore-
prefix will be added to the name.
Type:
Feel free to share topic-related thoughts here.
If you have technical questions, please create a support ticket in the DevExpress Support Center.
Thank you for the feedback!
If you have technical questions, please create a support ticket in the DevExpress Support Center.