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

Function createUsersCollection

packages/db/tests/query/distinct.test.ts:113–122  ·  view source on GitHub ↗
(autoIndex: `off` | `eager` = `eager`)

Source from the content-addressed store, hash-verified

111]
112
113function createUsersCollection(autoIndex: `off` | `eager` = `eager`) {
114 return createCollection(
115 mockSyncCollectionOptions<User>({
116 id: `test-users`,
117 getKey: (user) => user.id,
118 initialData: sampleUsers,
119 autoIndex,
120 }),
121 )
122}
123
124function createDistinctTests(autoIndex: `off` | `eager`): void {
125 describe(`with autoIndex ${autoIndex}`, () => {

Callers 1

createDistinctTestsFunction · 0.70

Calls 2

createCollectionFunction · 0.85

Tested by

no test coverage detected