What problem does it solve?
This Skill provides clear guidelines and utilities for managing state within the Vultisig codebase, ensuring consistency, maintainability, and efficient data flow across different parts of the application (desktop and extension).
Core Features & Use Cases
- State Provider: For mutable, component-local state using React Context.
- Value Provider: For read-only, globally accessible state.
- Persistent State: For storing state that survives reloads and can sync across tabs (desktop).
- Validation: Ensures the integrity of persisted state values.
- Component Autonomy: Promotes clean prop-passing by encouraging components to fetch their own state.
- Use Case: When developing a new feature that requires managing user preferences that should persist across browser sessions and be accessible by multiple components, consult this guide to implement it using the appropriate persistent state hook.
Quick Start
Use the state skill to implement a persistent state hook for managing user theme preferences.