MCPcopy Index your code
hub / github.com/TanStack/db / getFromSources

Function getFromSources

packages/db/src/query/optimizer.ts:903–911  ·  view source on GitHub ↗
(from: From)

Source from the content-addressed store, hash-verified

901}
902
903function getFromSources(from: From): Array<CollectionRefClass | QueryRefClass> {
904 if (from.type === `unionFrom`) {
905 return from.sources
906 }
907 if (from.type === `unionAll`) {
908 return []
909 }
910 return [from]
911}
912
913function getFirstFromAlias(query: QueryIR): string | undefined {
914 return getFromSources(query.from)[0]?.alias

Callers 3

isCollectionReferenceFunction · 0.70
getNullableJoinSourcesFunction · 0.70
getFirstFromAliasFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected