Represents a mutable piece of reactive grid state. This atom allows reading, updating, watching, and consuming its value reactively within React components.
Retrieves the current value stored in the atom. This method provides read access to the state managed by the atom.
This function takes no parameters.
T
Updates the atom's value. Accepts either a new value or a function that receives the current value and returns the updated value.
v | T | (p: ) => T |
void
A React hook that subscribes to the atom's value and causes the component to re-render whenever the atom changes.
This function takes no parameters.
T
Registers a listener function to be invoked whenever the atom's value changes. Returns a cleanup function to remove the listener.
fn | () => void |
() => void
Represents an immutable version of a grid atom that supports read, watch, and reactive usage but does not allow updates.
Retrieves the current value stored in the atom. This method provides read access to the state managed by the atom.
This function takes no parameters.
T
A React hook that subscribes to the atom's value and causes the component to re-render whenever the atom changes.
This function takes no parameters.
T
Registers a listener function to be invoked whenever the atom's value changes. Returns a cleanup function to remove the listener.
fn | () => void |
() => void
Represents the most minimal read-only version of a grid atom. It supports value retrieval and reactive consumption, but not watching or updates.
Retrieves the current value stored in the atom. This method provides read access to the state managed by the atom.
This function takes no parameters.
T
A React hook that subscribes to the atom's value and causes the component to re-render whenever the atom changes.
This function takes no parameters.
T