MCPcopy
hub / github.com/tinyplex/tinybase / useSetRowCallback

Function useSetRowCallback

src/ui-react/hooks.ts:950–968  ·  view source on GitHub ↗
(
  tableId: Id | GetId<Parameter>,
  rowId: Id | GetId<Parameter>,
  getRow: (parameter: Parameter, store: Store) => Row,
  getRowDeps?: DependencyList,
  storeOrStoreId?: StoreOrStoreId,
  then?: (store: Store, row: Row) => void,
  thenDeps?: DependencyList,
)

Source from the content-addressed store, hash-verified

948 );
949
950export const useSetRowCallback: typeof useSetRowCallbackDecl = <Parameter>(
951 tableId: Id | GetId<Parameter>,
952 rowId: Id | GetId<Parameter>,
953 getRow: (parameter: Parameter, store: Store) => Row,
954 getRowDeps?: DependencyList,
955 storeOrStoreId?: StoreOrStoreId,
956 then?: (store: Store, row: Row) => void,
957 thenDeps?: DependencyList,
958): ParameterizedCallback<Parameter> =>
959 useStoreSetCallback(
960 storeOrStoreId,
961 ROW,
962 getRow,
963 getRowDeps,
964 then,
965 thenDeps,
966 tableId,
967 rowId,
968 );
969
970export const useAddRowCallback: typeof useAddRowCallbackDecl = <Parameter>(
971 tableId: Id | GetId<Parameter>,

Callers 7

WriterFunction · 0.90
TestFunction · 0.90
useRowStateFunction · 0.90
AddRowFunction · 0.90
CloneRowFunction · 0.90
SettersFunction · 0.50
SettersFunction · 0.50

Calls 1

useStoreSetCallbackFunction · 0.70

Tested by 2

WriterFunction · 0.72
TestFunction · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…