MCPcopy Create free account
hub / github.com/TanStack/db / makeDisjunction

Function makeDisjunction

packages/db/src/query/predicate-utils.ts:46–56  ·  view source on GitHub ↗
(
  preds: Array<BasicExpression<boolean>>,
)

Source from the content-addressed store, hash-verified

44}
45
46function makeDisjunction(
47 preds: Array<BasicExpression<boolean>>,
48): BasicExpression<boolean> {
49 if (preds.length === 0) {
50 return new Value(false)
51 }
52 if (preds.length === 1) {
53 return preds[0]!
54 }
55 return new Func(`or`, preds)
56}
57
58function convertInToOr(inField: InField) {
59 const equalities = inField.values.map(

Callers 1

convertInToOrFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected