MCPcopy Index your code
hub / github.com/effector/effector / assertNodeSet

Function assertNodeSet

src/effector/is.ts:36–49  ·  view source on GitHub ↗
(
  value: unknown,
  method: string,
  valueName: string,
)

Source from the content-addressed store, hash-verified

34 )
35
36export const assertNodeSet = (
37 value: unknown,
38 method: string,
39 valueName: string,
40) => {
41 if (Array.isArray(value)) {
42 forEach(value, (item, i) =>
43 assertNodeSetItem(item, method, `${i} item of ${valueName}`, ''),
44 )
45 } else {
46 //@ts-expect-error some ts assertion edge case
47 assertNodeSetItem(value, method, valueName, ' or array of units')
48 }
49}
50
51export const assertTarget = (
52 method: string,

Callers 4

mergeFunction · 0.90
onFunction · 0.90
forwardFunction · 0.90
createSamplingFunction · 0.90

Calls 2

forEachFunction · 0.90
assertNodeSetItemFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…