TinyBase logoTinyBase β

Store hooks

This is the collection of store hooks within the ui-react module. There are 64 store hooks in total.

useCreateMergeableStore

The useCreateMergeableStore hook.

Read more

useCreateStore

The useCreateStore hook is used to create a Store within a React application with convenient memoization.

Read more

useProvideStore

The useProvideStore hook is used to add a Store object by Id to a Provider component, but imperatively from a component within it.

Read more

useStore

The useStore hook is used to get a reference to a Store from within a Provider component context.

Read more

useStoreIds

The useStoreIds hook is used to retrieve the Ids of all the named Store objects present in the current Provider component context.

Read more

useStoreOrStoreById

The useStoreOrStoreById hook is used to get a reference to a Store object from within a Provider component context, or have it passed directly to this hook.

Read more

useDelTablesCallback

The useDelTablesCallback hook returns a callback that can be used to remove all of the tabular data in a Store.

Read more

useHasTables

The useHasTables hook returns a boolean indicating whether any Table objects exist in the Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasTablesListener

The useHasTablesListener hook registers a listener function with the Store that will be called when Tables as a whole are added to or removed from the Store.

Read more

useSetTablesCallback

The useSetTablesCallback hook returns a parameterized callback that can be used to set the tabular data of a Store.

Read more

useTables

The useTables hook returns a Tables object containing the tabular data of a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useTablesListener

The useTablesListener hook registers a listener function with a Store that will be called whenever tabular data in it changes.

Read more

useTableIds

The useTableIds hook returns the Ids of every Table in a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useTableIdsListener

The useTableIdsListener hook registers a listener function with a Store that will be called whenever the Table Ids in it change.

Read more

useDelTableCallback

The useDelTableCallback hook returns a parameterized callback that can be used to remove a single Table from a Store.

Read more

useHasTable

The useHasTable hook returns a boolean indicating whether a given Table exists in the Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasTableCell

The useHasTableCell hook returns a boolean indicating whether a given Cell exists anywhere in a Table, not just in a specific Row, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasTableCellListener

The useHasTableCellListener hook registers a listener function with the Store that will be called when a Cell is added to or removed from anywhere in a Table as a whole.

Read more

useHasTableListener

The useHasTableListener hook registers a listener function with the Store that will be called when a Table is added to or removed from the Store.

Read more

useSetTableCallback

The useSetTableCallback hook returns a parameterized callback that can be used to set the data of a single Table in a Store.

Read more

useTable

The useTable hook returns an object containing the data of a single Table in a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useTableCellIds

The useTableCellIds hook returns the Ids of every Cell used across the whole Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useTableCellIdsListener

The useTableCellIdsListener hook registers a listener function with a Store that will be called whenever the Cell Ids that appear anywhere in a Table change.

Read more

useTableListener

The useTableListener hook registers a listener function with a Store that will be called whenever data in a Table changes.

Read more

useRowIds

The useRowIds hook returns the Ids of every Row in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useRowIdsListener

The useRowIdsListener hook registers a listener function with a Store that will be called whenever the Row Ids in a Table change.

Read more

useSortedRowIds

The useSortedRowIds hook returns the sorted (and optionally, paginated) Ids of every Row in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useSortedRowIdsListener

The useSortedRowIdsListener hook registers a listener function with a Store that will be called whenever sorted (and optionally, paginated) Row Ids in a Table change.

Read more

useAddRowCallback

The useAddRowCallback hook returns a parameterized callback that can be used to create a new Row in a Store.

Read more

useDelRowCallback

The useDelRowCallback hook returns a parameterized callback that can be used to remove a single Row from a Table.

Read more

useHasRow

The useHasRow hook returns a boolean indicating whether a given Row exists in the Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasRowListener

The useHasRowListener hook registers a listener function with the Store that will be called when a Row is added to or removed from the Store.

Read more

useRow

The useRow hook returns an object containing the data of a single Row in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useRowCount

The useRowCount hook returns the count of the Row objects in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useRowCountListener

The useRowCountListener hook registers a listener function with a Store that will be called whenever the count of the Row objects in a Table changes.

Read more

useRowListener

The useRowListener hook registers a listener function with a Store that will be called whenever data in a Row changes.

Read more

useSetPartialRowCallback

The useSetPartialRowCallback hook returns a parameterized callback that can be used to set partial data of a single Row in the Store, leaving other Cell values unaffected.

Read more

useSetRowCallback

The useSetRowCallback hook returns a parameterized callback that can be used to set the data of a single Row in a Store.

Read more

useCellIds

The useCellIds hook returns the Ids of every Cell in a given Row, in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useCellIdsListener

The useCellIdsListener hook registers a listener function with a Store that will be called whenever the Cell Ids in a Row change.

Read more

useCell

The useCell hook returns an object containing the value of a single Cell in a given Row, in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useCellListener

The useCellListener hook registers a listener function with a Store that will be called whenever data in a Cell changes.

Read more

useDelCellCallback

The useDelCellCallback hook returns a parameterized callback that can be used to remove a single Cell from a Row.

Read more

useHasCell

The useHasCell hook returns a boolean indicating whether a given Cell exists in a given Row in a given Table, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasCellListener

The useHasCellListener hook registers a listener function with the Store that will be called when a Cell is added to or removed from the Store.

Read more

useSetCellCallback

The useSetCellCallback hook returns a parameterized callback that can be used to set the value of a single Cell in a Store.

Read more

useDelValuesCallback

The useDelValuesCallback hook returns a callback that can be used to remove all of the keyed value data in a Store.

Read more

useHasValues

The useHasValues hook returns a boolean indicating whether any Values exist in the Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasValuesListener

The useHasValuesListener hook registers a listener function with the Store that will be called when Values as a whole are added to or removed from the Store.

Read more

useSetPartialValuesCallback

The useSetPartialValuesCallback hook returns a parameterized callback that can be used to set partial Values data in the Store, leaving other Values unaffected.

Read more

useSetValuesCallback

The useSetValuesCallback hook returns a parameterized callback that can be used to set the keyed value data of a Store.

Read more

useValues

The useValues hook returns a Values object containing the keyed value data of a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useValuesListener

The useValuesListener hook registers a listener function with a Store that will be called whenever keyed value data in it changes.

Read more

useDelValueCallback

The useDelValueCallback hook returns a parameterized callback that can be used to remove a single Value from a Store.

Read more

useHasValue

The useHasValue hook returns a boolean indicating whether a given Value exists in the Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useHasValueListener

The useHasValueListener hook registers a listener function with the Store that will be called when a Value is added to or removed from the Store.

Read more

useSetValueCallback

The useSetValueCallback hook returns a parameterized callback that can be used to set the data of a single Value in a Store.

Read more

useValue

The useValue hook returns an object containing the data of a single Value in a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useValueIds

The useValueIds hook returns the Ids of every Value in a Store, and registers a listener so that any changes to that result will cause a re-render.

Read more

useValueIdsListener

The useValueIdsListener hook registers a listener function with a Store that will be called whenever the Value Ids in it change.

Read more

useValueListener

The useValueListener hook registers a listener function with a Store that will be called whenever data in a Value changes.

Read more

useDidFinishTransactionListener

The useDidFinishTransactionListener hook registers a listener function with a Store that will be called just after other non-mutating listeners are called at the end of the transaction.

Read more

useStartTransactionListener

The useStartTransactionListener hook registers a listener function with the Store that will be called at the start of a transaction.

Read more

useWillFinishTransactionListener

The useWillFinishTransactionListener hook registers a listener function with a Store that will be called just before other non-mutating listeners are called at the end of the transaction.

Read more