Core Package Overview
@vef-framework-react/core is the runtime foundation of the framework. It does not contain UI components, but provides the infrastructure that all other packages depend on.
It covers eight areas:
- HTTP client and request lifecycle
- API client combining HTTP and React Query
- React Query integration
- Server-Sent Events (SSE)
- State management (Zustand stores and Jotai atoms)
- State machines (XState)
- Context providers
- Re-exports of motion, DnD, and Immer
Suggested Reading Order
Quick Reference
| Need | Export |
|---|---|
| Make HTTP requests | HttpClient, createHttpClient |
| Create API client | createApiClient, ApiClient |
| Query data | useQuery, useInfiniteQuery |
| Mutate data | useMutation |
| Global store | createStore, createPersistedStore |
| Component-scoped store | createComponentStore |
| Atom state | atom, useAtom, useAtomValue, useSetAtom |
| State machine | createMachine, useActor |
| App context | AppContextProvider, useAppContext |
| API client context | ApiClientProvider, useApiClient |
| SSE streaming | SseClient, createSseClient |
| Permission check | checkPermission |
| Immer mutation | produce, useImmer |