Instead of a typical 'Todo' app, which doesn't show how Stores interact with one another, this is a simple time tracking application.
Still a work in progress, but it gives you a good idea of how to use Storefront.
See it live here:
Projects
Maintains the list of projects you can log time to. See the schema...
Entries
Individual time entries, related to projects via a projectId
field. See the schema...
Timer
State for global timer object.
- UI starts a timer, sending the
Timer
store aprojectId
- UI stops the the timer:
Entries
store listens for theTimer_stop
action and creates an entry with the appropriate data.Projects
store listens for theEntries_add
action and updates thetime
attribute on the appropriate project.
- Full crud
- Persist to localStorage
- Add LessCss support