This repository was archived by the owner on Mar 15, 2022. It is now read-only.
Releases: ryangjchandler/spruce
Releases · ryangjchandler/spruce
v2.0.0
Added
- Added support for persisted stores. (#55)
Spruce.store('form', {
name: 'Ryan'
}, persisted = true)
Persisted stores use local storage to save state between page loads. On load, it will retrieve the state from a local storage key __spruce:${name}
.
When a persisted store is updated, it will push the changes to local storage under that same key by running the object through JSON.stringify()
.
Fixed
- Fixed problem with watchers ending up in an infinite loop.
Removed
- Removed all event bus related methods:
Spruce.on()
,Spruce.off()
,Spruce.emit()
andSpruce.once()
. (#48)
v1.1.2
1.1.2
v1.1.1
v1.1.0
Fixed
- Spruce will now react to changes made to
Array
using mutable methods such asArray.push()
.
v1.0.0
🚨 This is a major version and will include some breaking changes.
Added
- Added magic
$store
property using the "magic properties" API available in Alpine >= 2.5.0.
Removed
- Removed the need for
x-subscribe
. (#44) - Removed the
oldValue
argument fromSpruce.watch
callbacks. Callbacks will now only receive the current/new value.
Changes
- Spruce will only work with Alpine >= 2.5.0, so make sure to upgrade!