tldraw/packages
Steve Ruiz ed8d4d9e05
[improvement] store snapshot types (#1657)
This PR improves the types for the Store.

- renames `StoreSnapshot` to `SerializedStore`, which is the return type
of `Store.serialize`
- creates `StoreSnapshot` as a type for the return type of
`Store.getSnapshot` / the argument type for `Store.loadSnapshot`
- creates `TLStoreSnapshot` as the type used for the `TLStore`.

This came out of a session I had with a user. This should prevent
needing to import types from `@tldraw/store` directly.

### Change Type

- [x] `major` — Breaking change

### Test Plan

- [x] Unit Tests

### Release Notes

- [dev] Rename `StoreSnapshot` to `SerializedStore`
- [dev] Create new `StoreSnapshot` as type related to
`getSnapshot`/`loadSnapshot`
2023-06-27 12:25:55 +00:00
..
assets Revert "Update dependencies (#1613)" (#1617) 2023-06-19 09:49:44 +00:00
editor [improvement] store snapshot types (#1657) 2023-06-27 12:25:55 +00:00
file-format [improvement] store snapshot types (#1657) 2023-06-27 12:25:55 +00:00
indices update lazyrepo 2023-06-05 18:32:32 +01:00
polyfills Revert "Update dependencies (#1613)" (#1617) 2023-06-19 09:49:44 +00:00
primitives [refactor] snapping (#1589) 2023-06-15 14:36:46 +00:00
state Incorporate signia as @tldraw/state (#1620) 2023-06-20 13:31:26 +00:00
store [improvement] store snapshot types (#1657) 2023-06-27 12:25:55 +00:00
tldraw ShapeUtil refactor, Editor cleanup (#1611) 2023-06-19 14:01:18 +00:00
tlschema [improvement] store snapshot types (#1657) 2023-06-27 12:25:55 +00:00
ui Styles API follow-ups (#1636) 2023-06-24 13:46:04 +00:00
utils Styles API (#1580) 2023-06-16 10:33:47 +00:00
validate Styles API (#1580) 2023-06-16 10:33:47 +00:00