Skip to content

Commit dbffec8

Browse files
authored
refactor(ts-client): modularize selection-set (#806)
1 parent 5b13f30 commit dbffec8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+483
-412
lines changed

src/entrypoints/alpha/client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
export * from '../../layers/4_client/client.js'
2-
export { create as createSelect, select } from '../../layers/4_select/select.js'
1+
export * from '../../layers/5_client/client.js'
2+
export { create as createSelect, select } from '../../layers/5_select/select.js'

src/entrypoints/alpha/schema.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export * from '../../layers/1_Schema/__.js'
2-
export { ResultSet } from '../../layers/3_IO/ResultSet/__.js'
3-
export { SelectionSet } from '../../layers/3_IO/SelectionSet/__.js'
2+
export { SelectionSet } from '../../layers/3_SelectionSet/__.js'
3+
export { ResultSet } from '../../layers/4_ResultSet/__.js'

src/layers/3_IO/ResultSet/__.ts

Lines changed: 0 additions & 1 deletion
This file was deleted.

src/layers/3_IO/SelectionSet/_.ts

Lines changed: 0 additions & 2 deletions
This file was deleted.

src/layers/3_IO/SelectionSet/toGraphQLDocumentString.ts

Lines changed: 0 additions & 329 deletions
This file was deleted.

src/layers/3_SelectionSet/_.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export * as Print from './encode.js'
2+
export * from './types.js'
File renamed without changes.

src/layers/3_IO/SelectionSet/toGraphQLDocumentString.test.ts renamed to src/layers/3_SelectionSet/encode.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import { parse, print } from 'graphql'
22
import { describe, expect, test } from 'vitest'
3-
import type { Index } from '../../../../tests/_/schema/generated/Index.js'
4-
import { $Index as schemaIndex } from '../../../../tests/_/schema/generated/SchemaRuntime.js'
3+
import type { Index } from '../../../tests/_/schema/generated/Index.js'
4+
import { $Index as schemaIndex } from '../../../tests/_/schema/generated/SchemaRuntime.js'
55
import type { SelectionSet } from './__.js'
6-
import type { Context } from './toGraphQLDocumentString.js'
7-
import { rootTypeSelectionSet } from './toGraphQLDocumentString.js'
6+
import type { Context } from './encode.js'
7+
import { rootTypeSelectionSet } from './encode.js'
88

99
// eslint-disable-next-line
1010
// @ts-ignore

0 commit comments

Comments
 (0)