Releases: hazae41/glacier
Releases · hazae41/glacier
1.4.1-0
1.4.0 - Results
BREAKING
- Renamed Result to ResultInit
Non breaking
- New Result type which follows wrapper.unwrap() pattern
- Result.from(init) converts a ResultInit into a Result
- Result.map(callback) maps the result data into another type
- Result.unwrap() returns the data or throws the error
- Result.rewrap(wrapper) transforms a wrapper (an object with unwrap()) into a Result
- Result.wrap(callback) and Result.wrapSync(callback) can wrap a throwable callback into a Result
Fixes
- Fixed a bug with normalization and storage
1.3.0 - Safer lock management
NO BREAKING CHANGE ✅
No new features or usage, lot of bugs were fixed but maybe new bugs arrived
1.2.4 - Renamed things && Schemas early return
BREAKING
- Renamed
useQuery
touseSchema
(oruseScrollSchema
) - Renamed
useSingleQuery
touseQuery
NOT BREAKING
- Allow schema factories to return undefined:
function getHello(socket?: WebSocket) {
if (!socket) return
return getSchema("hello", key => fetcher(key, socket))
}
1.2.2 - Clean
BREAKING
- Made Core fields private
1.2.1 - ESNext
- removed tslib dependency
1.2.0 - Improved type system
- BREAKING:
error
is no longer typed, it is alwaysunknown
, just like in a try-catch block
Migration:
// previously
useSingleSchema<Data, Error, Key>(key, fetcher, params)
// now
useSingleSchema<Data, Key>(key, fetcher, params)
- BREAKING:
serializer
andnormalizer
are no longer allowed in global params - less verbose type system
- removed all
any
types
1.1.14 - Fix optimistic
- Optimistics now rollback to realData
1.1.13 - Fix for React strict mode
- Fixed core mounting in React strict mode
- Fixed garbage collection
- Maybe other bugs?
1.1.12 - Rollup and updates
- Unified Rollup config
- Updated deps
- modified react peer dependenct to >=17
- moved tslib as dependency