sebn/moka — pull request #16 by sebn (2014-06-17 17:17:41+00:00)
Title: Localstorage cleanup

This is still WIP.
Making a pull request to get early feedback.

- [x] Extract a base class for stores
- [x] Extract a function to append an object in a localStorage array item
- [x] Do not override `record` variable in `save()`
- [x] Extract a function to put an object in localStorage
- [ ] Extract a function to get an object from localStorage
- [ ] Extract key separator
- [ ] Extract key construction from joining multiple fragments
- [ ] Extract key prefixing
- [ ] Extract and implement a real random id generator
- [ ] Generalize record building (to get rid of custom `buildRecord()` methods
- [ ] Maybe drop pluralName / only use singularName? I mean, who cares about plural key names?
- [ ] Should we use "key" (as in "key-value store"), or "property" (as in JS / localStorage API) ?
- [ ] Maybe improve `unserializeProperties()` ?
- [ ] Extract common utils test setup?