[ALOY-1293] Add JSON sync adapter
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | None |
Status | Open |
Resolution | Unresolved |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Models |
Labels | n/a |
Reporter | Fokke Zandbergen |
Assignee | Bruce Wayne |
Created | 2015-07-10T14:49:48.000+0000 |
Updated | 2015-07-10T14:52:18.000+0000 |
Description
Much like ALOY-1292, as another alternative to SQLite and Properties it would be great to have a JSON sync adapter to read and (if the source allows) write from a JSON file that would need to be as:
[
{
// record
},
{
// record
}
// ...
]
The use case would be smaller sets of data that you don't want to first read into an SQLite DB or Properties and then need to do migrations when you have an app update. So most of the times this would just be a JSON files in the resources directory that wouldn't change.
We could use the one I included in my one-day tutorial: https://github.com/FokkeZB/Tutorial/edit/master/app/lib/alloy/sync/json.js
PR on master with read-only version: https://github.com/appcelerator/alloy/pull/709