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

Function replaceIncludesValue

packages/db/src/query/compiler/index.ts:1977–1990  ·  view source on GitHub ↗
(
  value: any,
  replacement: ValClass,
)

Source from the content-addressed store, hash-verified

1975}
1976
1977function replaceIncludesValue(
1978 value: any,
1979 replacement: ValClass,
1980): { value: any; replaced: boolean } {
1981 if (value instanceof IncludesSubquery) {
1982 return { value: replacement, replaced: true }
1983 }
1984
1985 if (value instanceof ConditionalSelect) {
1986 return replaceIncludesInConditionalSelect(value, [], replacement)
1987 }
1988
1989 return { value, replaced: false }
1990}
1991
1992function replaceIncludesInConditionalSelect(
1993 conditional: ConditionalSelect,

Calls 1

Tested by

no test coverage detected