问题标签 [applicationsettingsbase]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
163 浏览

storage - NativeScript best way of saving favorites

I am looking for correct and decent way of storing favorites articles in my app to phone storage. I built the app with Web shop articles listed and I would like to allow users to save favorite articles to the "favorite" list.

I have tried application-settings plugin and I am not sure is this a good way of doing it because keys needs to be predefined. (I am not really sure). Is there a some kind of JSON style data storage which does work on Android and iOS? - It would be great because I could sync it to Cloud storage at some point.

I need a easy way for manipulating data, add, remove, clear the list. Something what will not impact app performance. Cheers guys.

0 投票
0 回答
21 浏览

c# - 具有自定义类的自定义设置 - 序列化问题

我有一个自定义设置类,如下所示。

配置设置如下。

我正在尝试使用下面的代码访问 javascript 中的配置。

在调试时,我确实在 this["TextReplacementRules"] 中看到了 2 条记录,但是 JS 变量 - "configSetting" 在页面呈现后具有以下值。

似乎是序列化问题。我需要查看配置文件中设置的值。(2 条记录)。

请帮忙。