ClientState
Clientstate refers to data and UI state that resides on the client side, typically in a web browser, rather than on a server. It covers transient UI state (which component is visible), user preferences, draft form data, and cached data needed for rendering. Distinguishing client state from server state clarifies data authority: server state is the source of truth for business data, while client state is influenced by the user and the local environment and may be lost if the session ends.
Storage and persistence: In browsers, common mechanisms are in-memory variables, localStorage, sessionStorage, cookies, and IndexedDB. LocalStorage
Management: In single-page applications, client state is often managed with a central store and actions or mutations
Security and reliability: Because client state can be modified by users, servers should validate all critical
See also: server state, web storage APIs, offline web applications.