houdini 1.1.7 → 1.2.0-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/build/cmd-cjs/index.js +30737 -30175
- package/build/cmd-esm/index.js +30737 -30175
- package/build/codegen/generators/artifacts/selection.d.ts +2 -1
- package/build/codegen/generators/typescript/inlineType.d.ts +5 -2
- package/build/codegen/generators/typescript/loadingState.d.ts +8 -0
- package/build/codegen-cjs/index.js +30791 -30254
- package/build/codegen-esm/index.js +30791 -30254
- package/build/lib/code.d.ts +11 -0
- package/build/lib/config.d.ts +5 -0
- package/build/lib/graphql.d.ts +5 -1
- package/build/lib/index.d.ts +1 -0
- package/build/lib/parse.d.ts +0 -7
- package/build/lib/types.d.ts +4 -1
- package/build/lib-cjs/index.js +29888 -29668
- package/build/lib-esm/index.js +29885 -29668
- package/build/runtime/cache/cache.d.ts +5 -6
- package/build/runtime/client/documentStore.d.ts +3 -0
- package/build/runtime/client/index.d.ts +7 -6
- package/build/runtime/client/plugins/cache.d.ts +1 -1
- package/build/runtime/client/plugins/fetch.d.ts +1 -0
- package/build/runtime/client/plugins/subscription.d.ts +1 -0
- package/build/runtime/client/plugins/throwOnError.d.ts +2 -1
- package/build/runtime/lib/pageInfo.d.ts +7 -0
- package/build/runtime/lib/pagination.d.ts +27 -0
- package/build/runtime/lib/selection.d.ts +1 -1
- package/build/runtime/lib/types.d.ts +75 -3
- package/build/runtime-cjs/cache/cache.d.ts +5 -6
- package/build/runtime-cjs/cache/cache.js +78 -36
- package/build/runtime-cjs/cache/subscription.js +5 -5
- package/build/runtime-cjs/client/documentStore.d.ts +3 -0
- package/build/runtime-cjs/client/documentStore.js +20 -7
- package/build/runtime-cjs/client/index.d.ts +7 -6
- package/build/runtime-cjs/client/index.js +12 -4
- package/build/runtime-cjs/client/plugins/cache.d.ts +1 -1
- package/build/runtime-cjs/client/plugins/cache.js +12 -2
- package/build/runtime-cjs/client/plugins/fetch.d.ts +1 -0
- package/build/runtime-cjs/client/plugins/fetch.js +3 -2
- package/build/runtime-cjs/client/plugins/fragment.js +8 -1
- package/build/runtime-cjs/client/plugins/query.js +2 -1
- package/build/runtime-cjs/client/plugins/subscription.d.ts +1 -0
- package/build/runtime-cjs/client/plugins/subscription.js +1 -0
- package/build/runtime-cjs/client/plugins/throwOnError.d.ts +2 -1
- package/build/runtime-cjs/lib/config.js +2 -1
- package/build/runtime-cjs/lib/pageInfo.d.ts +7 -0
- package/build/runtime-cjs/lib/pageInfo.js +79 -0
- package/build/runtime-cjs/lib/pagination.d.ts +27 -0
- package/build/runtime-cjs/lib/pagination.js +219 -0
- package/build/runtime-cjs/lib/scalars.js +1 -1
- package/build/runtime-cjs/lib/selection.d.ts +1 -1
- package/build/runtime-cjs/lib/selection.js +28 -1
- package/build/runtime-cjs/lib/types.d.ts +75 -3
- package/build/runtime-cjs/lib/types.js +3 -0
- package/build/runtime-esm/cache/cache.d.ts +5 -6
- package/build/runtime-esm/cache/cache.js +79 -37
- package/build/runtime-esm/cache/subscription.js +5 -5
- package/build/runtime-esm/client/documentStore.d.ts +3 -0
- package/build/runtime-esm/client/documentStore.js +20 -7
- package/build/runtime-esm/client/index.d.ts +7 -6
- package/build/runtime-esm/client/index.js +15 -7
- package/build/runtime-esm/client/plugins/cache.d.ts +1 -1
- package/build/runtime-esm/client/plugins/cache.js +12 -2
- package/build/runtime-esm/client/plugins/fetch.d.ts +1 -0
- package/build/runtime-esm/client/plugins/fetch.js +3 -2
- package/build/runtime-esm/client/plugins/fragment.js +8 -1
- package/build/runtime-esm/client/plugins/query.js +2 -1
- package/build/runtime-esm/client/plugins/subscription.d.ts +1 -0
- package/build/runtime-esm/client/plugins/subscription.js +1 -0
- package/build/runtime-esm/client/plugins/throwOnError.d.ts +2 -1
- package/build/runtime-esm/lib/config.js +2 -1
- package/build/runtime-esm/lib/pageInfo.d.ts +7 -0
- package/build/runtime-esm/lib/pageInfo.js +52 -0
- package/build/runtime-esm/lib/pagination.d.ts +27 -0
- package/build/runtime-esm/lib/pagination.js +194 -0
- package/build/runtime-esm/lib/scalars.js +1 -1
- package/build/runtime-esm/lib/selection.d.ts +1 -1
- package/build/runtime-esm/lib/selection.js +28 -1
- package/build/runtime-esm/lib/types.d.ts +75 -3
- package/build/runtime-esm/lib/types.js +2 -0
- package/build/test/index.d.ts +15 -0
- package/build/test-cjs/index.js +30699 -30140
- package/build/test-esm/index.js +30699 -30140
- package/build/vite-cjs/index.js +30765 -30205
- package/build/vite-esm/index.js +30765 -30205
- package/package.json +5 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Options } from 'recast';
|
|
2
|
+
import type { Script } from './types';
|
|
3
|
+
type PrintOptions = Options & {
|
|
4
|
+
pretty?: boolean;
|
|
5
|
+
};
|
|
6
|
+
export declare function parseJS(code: string): Promise<Script>;
|
|
7
|
+
export declare function printJS(script: Script, options?: PrintOptions): Promise<{
|
|
8
|
+
code: string;
|
|
9
|
+
map?: any;
|
|
10
|
+
}>;
|
|
11
|
+
export {};
|
package/build/lib/config.d.ts
CHANGED
|
@@ -86,6 +86,8 @@ export declare class Config {
|
|
|
86
86
|
get listPrependDirective(): string;
|
|
87
87
|
get listAppendDirective(): string;
|
|
88
88
|
get listParentDirective(): string;
|
|
89
|
+
get blockingDirective(): string;
|
|
90
|
+
get blockingDisableDirective(): string;
|
|
89
91
|
/**
|
|
90
92
|
* @deprecated
|
|
91
93
|
*/
|
|
@@ -96,6 +98,7 @@ export declare class Config {
|
|
|
96
98
|
get removeFragmentSuffix(): string;
|
|
97
99
|
get toggleFragmentSuffix(): string;
|
|
98
100
|
get deleteDirectiveSuffix(): string;
|
|
101
|
+
get loadingDirective(): string;
|
|
99
102
|
get whenDirective(): string;
|
|
100
103
|
get whenNotDirective(): string;
|
|
101
104
|
get liveDirective(): string;
|
|
@@ -106,6 +109,7 @@ export declare class Config {
|
|
|
106
109
|
get cacheDirective(): string;
|
|
107
110
|
get cachePartialArg(): string;
|
|
108
111
|
get cachePolicyArg(): string;
|
|
112
|
+
get requiredDirective(): string;
|
|
109
113
|
paginationQueryName(documentName: string): string;
|
|
110
114
|
isDeleteDirective(name: string): boolean;
|
|
111
115
|
listDeleteDirective(name: string): string;
|
|
@@ -118,6 +122,7 @@ export declare class Config {
|
|
|
118
122
|
listRemoveFragment(name: string): string;
|
|
119
123
|
isInternalEnum(node: graphql.EnumTypeDefinitionNode): boolean;
|
|
120
124
|
isInternalDirective(name: string): boolean;
|
|
125
|
+
needsRefetchArtifact(document: graphql.DocumentNode): boolean;
|
|
121
126
|
registerFragmentVariablesHash({ hash, args, fragment, }: {
|
|
122
127
|
hash: string;
|
|
123
128
|
args: ValueMap | null;
|
package/build/lib/graphql.d.ts
CHANGED
|
@@ -6,8 +6,12 @@ export declare function hashDocument({ document, }: {
|
|
|
6
6
|
document: string | Document;
|
|
7
7
|
}): string;
|
|
8
8
|
type GraphQLParentType = graphql.GraphQLObjectType | graphql.GraphQLInputObjectType | graphql.GraphQLInterfaceType;
|
|
9
|
+
export declare function parentField(ancestors: readonly any[]): graphql.FieldNode | graphql.InlineFragmentNode | graphql.OperationDefinitionNode | graphql.FragmentDefinitionNode | null;
|
|
9
10
|
export declare function parentTypeFromAncestors(schema: graphql.GraphQLSchema, filepath: string, ancestors: readonly any[]): GraphQLParentType;
|
|
10
|
-
export declare function definitionFromAncestors(ancestors: readonly any[]):
|
|
11
|
+
export declare function definitionFromAncestors(ancestors: readonly any[]): {
|
|
12
|
+
parents: (graphql.OperationDefinitionNode | graphql.FragmentDefinitionNode | graphql.SelectionSetNode | graphql.FieldNode | graphql.InlineFragmentNode)[];
|
|
13
|
+
definition: graphql.OperationDefinitionNode | graphql.FragmentDefinitionNode;
|
|
14
|
+
};
|
|
11
15
|
export declare function formatErrors(e: unknown, afterError?: (e: Error) => void): void;
|
|
12
16
|
export declare function operation_requires_variables(operation: graphql.OperationDefinitionNode): boolean;
|
|
13
17
|
export declare function unwrapType(config: Config, type: any, wrappers?: TypeWrapper[]): {
|
package/build/lib/index.d.ts
CHANGED
package/build/lib/parse.d.ts
CHANGED
package/build/lib/types.d.ts
CHANGED
|
@@ -103,7 +103,10 @@ export type PluginHooks = {
|
|
|
103
103
|
transformRuntime?: Record<string, (args: {
|
|
104
104
|
config: Config;
|
|
105
105
|
content: string;
|
|
106
|
-
}) => string
|
|
106
|
+
}) => string> | ((docs: Document[]) => Record<string, (args: {
|
|
107
|
+
config: Config;
|
|
108
|
+
content: string;
|
|
109
|
+
}) => string>);
|
|
107
110
|
/**
|
|
108
111
|
* An module with an default export that sets configuration values.
|
|
109
112
|
*/
|