Initial plan commit
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Shared state lives in stores, not prop-drilling (spec §8.2 rule 3).
|
||||
* Mutation flow: component → api.js → update store from the response.
|
||||
* Svelte 5 runes style only (spec §8.2 rule 8).
|
||||
*/
|
||||
|
||||
// Current date as a YYYY-MM-DD string — the server never decides "today" (spec §8.1 rule 8)
|
||||
export const currentDate = $state({
|
||||
value: new Date().toISOString().slice(0, 10),
|
||||
})
|
||||
|
||||
// Today's log entries and current target, refreshed from the API after any mutation
|
||||
export const todayLog = $state({ entries: [], loading: false, error: null })
|
||||
export const currentTarget = $state({ target: null, loading: false, error: null })
|
||||
Reference in New Issue
Block a user