Functions
- loadAsyncData() — Loads asynchronous data into the global state,
the same way as useAsyncData(), and useAsyncCollection() hooks do. It is
intended for niche situations, where a direct, imperative manipulation of
the global state is prefferable to those hooks, and
.reload()methods they provide. - newAsyncDataEnvelope() — Creates a new plain JS object, satisfying the AsyncDataEnvelopeT type, and with reasonable initial values of its fields.
- withGlobalStateType() — Returns a set of library components, classes, and hooks "locked-in" onto a specified state type. Thus, making it unnecessary (in TypeScript) to pass the state type as a generic parameter for each component, class, and hook, when they are used, and allowing TypeScript compiler to auto-evaluate their other generic parameters in many cases.
Deprecated
- getGlobalState() — Renamed into useGlobalStateObject() in v0.24.0.
- getSsrContext() — Renamed into useSsrContext() in v0.24.0.