MCPcopy Index your code
hub / github.com/tinyplex/tinybase / objGet

Function objGet

src/common/obj.ts:36–39  ·  view source on GitHub ↗
(
  obj: IdObj<Value> | Value[] | undefined,
  id: Id,
)

Source from the content-addressed store, hash-verified

34 object.assign({}, ...objs);
35
36export const objGet = <Value>(
37 obj: IdObj<Value> | Value[] | undefined,
38 id: Id,
39): Value | undefined => ifNotUndefined(obj, (obj) => (obj as IdObj<Value>)[id]);
40
41export const objHas = (obj: IdObj<unknown>, id: Id): boolean => id in obj;
42

Callers 7

ProviderFunction · 0.90
useThingFunction · 0.90
addExtraThingByIdFunction · 0.90
useThingFunction · 0.90
paramFunction · 0.90
applyChangesToDocFunction · 0.90
getThingFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…