grafast 0.0.0 → 0.0.1-0.1
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/LICENSE.md +26 -0
- package/README.md +3 -1
- package/dist/LICENSES.txt +273 -0
- package/dist/args.d.ts +3 -0
- package/dist/assert.d.ts +3 -0
- package/dist/bucket.d.ts +24 -0
- package/dist/config.d.ts +9 -0
- package/dist/constraints.d.ts +30 -0
- package/dist/deferred.d.ts +6 -0
- package/dist/dev.d.ts +3 -0
- package/dist/envelop.d.ts +7 -0
- package/dist/envelop.js +1 -0
- package/dist/error.d.ts +13 -0
- package/dist/establishOperationPlan.d.ts +9 -0
- package/dist/execute.d.ts +5 -0
- package/dist/exportAs.d.ts +5 -0
- package/dist/global.d.ts +3 -0
- package/dist/grafastGraphql.d.ts +5 -0
- package/dist/grafastPrint.d.ts +5 -0
- package/dist/graphqlCollectFields.d.ts +12 -0
- package/dist/graphqlMergeSelectionSets.d.ts +4 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.js +169 -0
- package/dist/input.d.ts +11 -0
- package/dist/inspect.d.ts +4 -0
- package/dist/interfaces.d.ts +261 -0
- package/dist/makeGrafastSchema.d.ts +52 -0
- package/dist/mermaid.d.ts +15 -0
- package/dist/opPlan-input.d.ts +6 -0
- package/dist/polymorphic.d.ts +6 -0
- package/dist/prepare.d.ts +11 -0
- package/dist/step.d.ts +104 -0
- package/dist/stringifyPayload.d.ts +3 -0
- package/dist/stripAnsi.d.ts +3 -0
- package/dist/subscribe.d.ts +4 -0
- package/dist/utils.d.ts +60 -0
- package/package.json +60 -9
- package/index.js +0 -1
package/dist/input.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { GraphQLInputType, GraphQLType, ListTypeNode, NamedTypeNode, NonNullTypeNode, ValueNode } from "graphql";
|
|
2
|
+
import type { OperationPlan } from "./engine/OperationPlan.js";
|
|
3
|
+
import { __InputDynamicScalarStep } from "./steps/__inputDynamicScalar.js";
|
|
4
|
+
import { __InputObjectStep } from "./steps/__inputObject.js";
|
|
5
|
+
import type { ConstantStep } from "./steps/index.js";
|
|
6
|
+
import { __InputListStep, __InputStaticLeafStep, __TrackedObjectStep } from "./steps/index.js";
|
|
7
|
+
export declare type InputStep = __TrackedObjectStep | __InputListStep | __InputStaticLeafStep | __InputDynamicScalarStep | __InputObjectStep | ConstantStep<undefined>;
|
|
8
|
+
export declare function assertInputStep(itemPlan: unknown): asserts itemPlan is InputStep;
|
|
9
|
+
export declare function graphqlGetTypeForNode(operationPlan: OperationPlan, node: NamedTypeNode | ListTypeNode | NonNullTypeNode): GraphQLType;
|
|
10
|
+
export declare function inputPlan(operationPlan: OperationPlan, inputType: GraphQLInputType, seenTypes: Set<GraphQLInputType>, rawInputValue: ValueNode | undefined, defaultValue?: ValueNode | undefined): InputStep;
|
|
11
|
+
//# sourceMappingURL=input.d.ts.map
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
import type EventEmitter from "eventemitter3";
|
|
2
|
+
import type { PluginHook } from "graphile-config";
|
|
3
|
+
import type { ASTNode, ExecutionArgs, GraphQLArgument, GraphQLArgumentConfig, GraphQLField, GraphQLFieldConfig, GraphQLInputField, GraphQLInputFieldConfig, GraphQLInputObjectType, GraphQLInputType, GraphQLList, GraphQLNonNull, GraphQLOutputType, GraphQLScalarType, GraphQLSchema, GraphQLType } from "graphql";
|
|
4
|
+
import type { Bucket, RequestContext } from "./bucket.js";
|
|
5
|
+
import type { GrafastError } from "./error.js";
|
|
6
|
+
import type { InputStep } from "./input.js";
|
|
7
|
+
import type { ExecutableStep, ListCapableStep, ModifierStep } from "./step.js";
|
|
8
|
+
import type { GraphileInputObjectType, GraphileObjectType } from "./utils.js";
|
|
9
|
+
declare type PromiseOrValue<T> = T | Promise<T>;
|
|
10
|
+
export interface GrafastOptions {
|
|
11
|
+
context?: Record<string, any> | (<TContext extends Record<string, any>>(ctx: GraphileConfig.GraphQLRequestContext, currentContext?: Partial<TContext>) => PromiseOrValue<Partial<TContext>>);
|
|
12
|
+
explain?: boolean | string[];
|
|
13
|
+
}
|
|
14
|
+
declare global {
|
|
15
|
+
namespace GraphileConfig {
|
|
16
|
+
interface GraphQLRequestContext {
|
|
17
|
+
}
|
|
18
|
+
interface Preset {
|
|
19
|
+
grafast?: GrafastOptions;
|
|
20
|
+
}
|
|
21
|
+
interface GrafastHooks {
|
|
22
|
+
args: PluginHook<(event: {
|
|
23
|
+
args: ExecutionArgs;
|
|
24
|
+
ctx: GraphileConfig.GraphQLRequestContext;
|
|
25
|
+
resolvedPreset: GraphileConfig.ResolvedPreset;
|
|
26
|
+
}) => PromiseOrValue<ExecutionArgs>>;
|
|
27
|
+
}
|
|
28
|
+
interface Plugin {
|
|
29
|
+
grafast?: {
|
|
30
|
+
hooks?: GrafastHooks;
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
export interface GrafastFieldExtensions {
|
|
36
|
+
plan?: FieldPlanResolver<any, any, any>;
|
|
37
|
+
subscribePlan?: FieldPlanResolver<any, any, any>;
|
|
38
|
+
}
|
|
39
|
+
export interface GrafastArgumentExtensions {
|
|
40
|
+
inputPlan?: ArgumentInputPlanResolver;
|
|
41
|
+
applyPlan?: ArgumentApplyPlanResolver;
|
|
42
|
+
}
|
|
43
|
+
export interface GrafastInputObjectTypeExtensions {
|
|
44
|
+
inputPlan?: InputObjectTypeInputPlanResolver;
|
|
45
|
+
}
|
|
46
|
+
export interface GrafastInputFieldExtensions {
|
|
47
|
+
inputPlan?: InputObjectFieldInputPlanResolver;
|
|
48
|
+
applyPlan?: InputObjectFieldApplyPlanResolver;
|
|
49
|
+
}
|
|
50
|
+
export interface GrafastObjectTypeExtensions {
|
|
51
|
+
Step?: {
|
|
52
|
+
new (...args: any[]): ExecutableStep;
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
export interface GrafastEnumTypeExtensions {
|
|
56
|
+
}
|
|
57
|
+
export interface GrafastEnumValueExtensions {
|
|
58
|
+
applyPlan?: EnumValueApplyPlanResolver<any>;
|
|
59
|
+
}
|
|
60
|
+
export interface GrafastScalarTypeExtensions {
|
|
61
|
+
plan?: ScalarPlanResolver;
|
|
62
|
+
inputPlan?: ScalarInputPlanResolver;
|
|
63
|
+
idempotent?: boolean;
|
|
64
|
+
}
|
|
65
|
+
declare module "graphql" {
|
|
66
|
+
interface GraphQLFieldExtensions<_TSource, _TContext, _TArgs = any> {
|
|
67
|
+
graphile?: GrafastFieldExtensions;
|
|
68
|
+
}
|
|
69
|
+
interface GraphQLArgumentExtensions {
|
|
70
|
+
graphile?: GrafastArgumentExtensions;
|
|
71
|
+
}
|
|
72
|
+
interface GraphQLInputObjectTypeExtensions {
|
|
73
|
+
graphile?: GrafastInputObjectTypeExtensions;
|
|
74
|
+
}
|
|
75
|
+
interface GraphQLInputFieldExtensions {
|
|
76
|
+
graphile?: GrafastInputFieldExtensions;
|
|
77
|
+
}
|
|
78
|
+
interface GraphQLObjectTypeExtensions<_TSource = any, _TContext = any> {
|
|
79
|
+
graphile?: GrafastObjectTypeExtensions;
|
|
80
|
+
}
|
|
81
|
+
interface GraphQLEnumTypeExtensions {
|
|
82
|
+
graphile?: GrafastEnumTypeExtensions;
|
|
83
|
+
}
|
|
84
|
+
interface GraphQLEnumValueExtensions {
|
|
85
|
+
graphile?: GrafastEnumValueExtensions;
|
|
86
|
+
}
|
|
87
|
+
interface GraphQLScalarTypeExtensions {
|
|
88
|
+
graphile?: GrafastScalarTypeExtensions;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
export declare const $$grafastContext: unique symbol;
|
|
92
|
+
export declare const $$planResults: unique symbol;
|
|
93
|
+
export declare const $$id: unique symbol;
|
|
94
|
+
export declare const $$verbatim: unique symbol;
|
|
95
|
+
export declare const $$bypassGraphQL: unique symbol;
|
|
96
|
+
export declare const $$data: unique symbol;
|
|
97
|
+
export declare const $$extensions: unique symbol;
|
|
98
|
+
export declare const $$concreteType: unique symbol;
|
|
99
|
+
export declare const $$idempotent: unique symbol;
|
|
100
|
+
export declare const $$eventEmitter: unique symbol;
|
|
101
|
+
export declare const $$streamMore: unique symbol;
|
|
102
|
+
export declare const $$proxy: unique symbol;
|
|
103
|
+
export interface PolymorphicData<TType extends string = string, TData = any> {
|
|
104
|
+
[$$concreteType]: TType;
|
|
105
|
+
[$$data]?: TData;
|
|
106
|
+
}
|
|
107
|
+
export interface IndexByListItemStepId {
|
|
108
|
+
[listItemStepId: number]: number;
|
|
109
|
+
}
|
|
110
|
+
export declare type GrafastValuesList<T> = ReadonlyArray<T>;
|
|
111
|
+
export declare type PromiseOrDirect<T> = PromiseLike<T> | T;
|
|
112
|
+
export declare type GrafastResultsList<T> = ReadonlyArray<PromiseOrDirect<T>>;
|
|
113
|
+
export declare type GrafastResultStreamList<T> = ReadonlyArray<AsyncIterable<PromiseOrDirect<T>> | GrafastError>;
|
|
114
|
+
export declare type BaseGraphQLRootValue = any;
|
|
115
|
+
export interface BaseGraphQLContext {
|
|
116
|
+
}
|
|
117
|
+
export interface BaseGraphQLVariables {
|
|
118
|
+
[key: string]: unknown;
|
|
119
|
+
}
|
|
120
|
+
export interface BaseGraphQLArguments {
|
|
121
|
+
[key: string]: any;
|
|
122
|
+
}
|
|
123
|
+
export declare type BaseGraphQLInputObject = BaseGraphQLArguments;
|
|
124
|
+
export interface FieldArgs {
|
|
125
|
+
get(path?: string | string[]): ExecutableStep;
|
|
126
|
+
getRaw(path?: string | string[]): InputStep;
|
|
127
|
+
apply($target: ExecutableStep | ModifierStep, path?: string | string[]): void;
|
|
128
|
+
}
|
|
129
|
+
export interface FieldInfo {
|
|
130
|
+
field: GraphQLField<any, any, any>;
|
|
131
|
+
schema: GraphQLSchema;
|
|
132
|
+
}
|
|
133
|
+
export declare type FieldPlanResolver<_TArgs extends BaseGraphQLArguments, TParentStep extends ExecutableStep<any> | null, TResultStep extends ExecutableStep<any>> = ($parentPlan: TParentStep, args: FieldArgs, info: FieldInfo) => TResultStep | null;
|
|
134
|
+
export declare type InputObjectFieldInputPlanResolver<TResultStep extends ExecutableStep<any> = ExecutableStep<any>> = (input: FieldArgs, info: {
|
|
135
|
+
schema: GraphQLSchema;
|
|
136
|
+
entity: GraphQLInputField;
|
|
137
|
+
}) => TResultStep;
|
|
138
|
+
export declare type InputObjectFieldApplyPlanResolver<TFieldStep extends ExecutableStep<any> | ModifierStep<any> = ExecutableStep<any> | ModifierStep<any>, TResultStep extends ModifierStep<ExecutableStep<any> | ModifierStep<any>> | null | void = ModifierStep<ExecutableStep<any> | ModifierStep<any>> | null | void> = ($fieldPlan: TFieldStep, input: FieldArgs, info: {
|
|
139
|
+
schema: GraphQLSchema;
|
|
140
|
+
entity: GraphQLInputField;
|
|
141
|
+
}) => TResultStep;
|
|
142
|
+
export declare type InputObjectTypeInputPlanResolver = (input: FieldArgs, info: {
|
|
143
|
+
schema: GraphQLSchema;
|
|
144
|
+
type: GraphQLInputObjectType;
|
|
145
|
+
}) => ExecutableStep;
|
|
146
|
+
export declare type ArgumentInputPlanResolver<TParentStep extends ExecutableStep<any> = ExecutableStep<any>, TResultStep extends ExecutableStep<any> = ExecutableStep<any>> = ($parentPlan: TParentStep, input: FieldArgs, info: {
|
|
147
|
+
schema: GraphQLSchema;
|
|
148
|
+
entity: GraphQLArgument;
|
|
149
|
+
}) => TResultStep;
|
|
150
|
+
export declare type ArgumentApplyPlanResolver<TParentStep extends ExecutableStep<any> = ExecutableStep<any>, TFieldStep extends ExecutableStep<any> | ModifierStep<any> = ExecutableStep<any> | ModifierStep<any>, TResultStep extends ExecutableStep | ModifierStep<ExecutableStep | ModifierStep> | null | void = ExecutableStep | ModifierStep<ExecutableStep | ModifierStep> | null | void> = ($parentPlan: TParentStep, $fieldPlan: TFieldStep, input: FieldArgs, info: {
|
|
151
|
+
schema: GraphQLSchema;
|
|
152
|
+
entity: GraphQLArgument;
|
|
153
|
+
}) => TResultStep;
|
|
154
|
+
export declare type ScalarPlanResolver<TParentStep extends ExecutableStep<any> = ExecutableStep<any>, TResultStep extends ExecutableStep<any> = ExecutableStep<any>> = ($parentPlan: TParentStep, info: {
|
|
155
|
+
schema: GraphQLSchema;
|
|
156
|
+
}) => TResultStep;
|
|
157
|
+
export declare type ScalarInputPlanResolver<TResultStep extends ExecutableStep<any> = ExecutableStep<any>> = ($inputValue: InputStep, info: {
|
|
158
|
+
schema: GraphQLSchema;
|
|
159
|
+
type: GraphQLScalarType;
|
|
160
|
+
}) => TResultStep;
|
|
161
|
+
export declare type EnumValueApplyPlanResolver<TParentStep extends ExecutableStep | ModifierStep = ExecutableStep | ModifierStep> = ($parent: TParentStep) => ModifierStep | void;
|
|
162
|
+
declare type OutputPlanForNamedType<TType extends GraphQLType> = TType extends GraphileObjectType<any, infer TStep, any> ? TStep : ExecutableStep<any>;
|
|
163
|
+
export declare type OutputPlanForType<TType extends GraphQLOutputType> = TType extends GraphQLNonNull<GraphQLList<GraphQLNonNull<infer U>>> ? ListCapableStep<any, OutputPlanForNamedType<U>> : TType extends GraphQLNonNull<GraphQLList<infer U>> ? ListCapableStep<any, OutputPlanForNamedType<U>> : TType extends GraphQLList<GraphQLNonNull<infer U>> ? ListCapableStep<any, OutputPlanForNamedType<U>> : TType extends GraphQLList<infer U> ? ListCapableStep<any, OutputPlanForNamedType<U>> : TType extends GraphQLNonNull<infer U> ? OutputPlanForNamedType<U> : OutputPlanForNamedType<TType>;
|
|
164
|
+
declare type InputPlanForNamedType<TType extends GraphQLType> = TType extends GraphileInputObjectType<any, infer U, any> ? U : ModifierStep<any>;
|
|
165
|
+
declare type InputPlanForType<TType extends GraphQLInputType> = TType extends GraphQLNonNull<GraphQLList<GraphQLNonNull<infer U>>> ? InputPlanForNamedType<U> : TType extends GraphQLNonNull<GraphQLList<infer U>> ? InputPlanForNamedType<U> : TType extends GraphQLList<GraphQLNonNull<infer U>> ? InputPlanForNamedType<U> : TType extends GraphQLList<infer U> ? InputPlanForNamedType<U> : TType extends GraphQLNonNull<infer U> ? InputPlanForNamedType<U> : InputPlanForNamedType<TType>;
|
|
166
|
+
declare type InputTypeForNamedType<TType extends GraphQLType> = TType extends GraphQLScalarType<infer U> ? U : any;
|
|
167
|
+
declare type InputTypeFor<TType extends GraphQLInputType> = TType extends GraphQLNonNull<GraphQLList<GraphQLNonNull<infer U>>> ? InputTypeForNamedType<U> : TType extends GraphQLNonNull<GraphQLList<infer U>> ? InputTypeForNamedType<U> : TType extends GraphQLList<GraphQLNonNull<infer U>> ? InputTypeForNamedType<U> : TType extends GraphQLList<infer U> ? InputTypeForNamedType<U> : TType extends GraphQLNonNull<infer U> ? InputTypeForNamedType<U> : InputTypeForNamedType<TType>;
|
|
168
|
+
export declare type GraphileFieldConfig<TType extends GraphQLOutputType, TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any> | null, TFieldStep extends ExecutableStep<any>, TArgs extends BaseGraphQLArguments> = Omit<GraphQLFieldConfig<any, any>, "args" | "type"> & {
|
|
169
|
+
type: TType;
|
|
170
|
+
plan?: FieldPlanResolver<TArgs, TParentStep, TFieldStep>;
|
|
171
|
+
subscribePlan?: FieldPlanResolver<TArgs, TParentStep, TFieldStep>;
|
|
172
|
+
args?: GraphileFieldConfigArgumentMap<TType, TContext, TParentStep, TFieldStep>;
|
|
173
|
+
};
|
|
174
|
+
export declare type GraphileFieldConfigArgumentMap<_TType extends GraphQLOutputType, TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any> | null, TFieldStep extends ExecutableStep<any>> = {
|
|
175
|
+
[argName: string]: GraphileArgumentConfig<any, TContext, TParentStep, TFieldStep, any, any>;
|
|
176
|
+
};
|
|
177
|
+
export declare type GraphileArgumentConfig<TInputType extends GraphQLInputType, _TContext extends BaseGraphQLContext, _TParentStep extends ExecutableStep<any> | null, TFieldStep extends ExecutableStep<any>, _TArgumentStep extends TFieldStep extends ExecutableStep<any> ? ModifierStep<TFieldStep> | null : null, _TInput extends InputTypeFor<TInputType>> = Omit<GraphQLArgumentConfig, "type"> & {
|
|
178
|
+
type: TInputType;
|
|
179
|
+
inputPlan?: ArgumentInputPlanResolver<any>;
|
|
180
|
+
applyPlan?: ArgumentApplyPlanResolver<any, any>;
|
|
181
|
+
};
|
|
182
|
+
export declare type GraphileInputFieldConfig<TInputType extends GraphQLInputType, _TContext extends BaseGraphQLContext, _TParentStep extends ModifierStep<any>, _TResultStep extends InputPlanForType<TInputType>, _TInput extends InputTypeFor<TInputType>> = Omit<GraphQLInputFieldConfig, "type"> & {
|
|
183
|
+
type: TInputType;
|
|
184
|
+
inputPlan?: InputObjectFieldInputPlanResolver;
|
|
185
|
+
applyPlan?: InputObjectFieldApplyPlanResolver<any>;
|
|
186
|
+
};
|
|
187
|
+
export declare type TrackedArguments<TArgs extends BaseGraphQLArguments = BaseGraphQLArguments> = {
|
|
188
|
+
get<TKey extends keyof TArgs>(key: TKey): InputStep;
|
|
189
|
+
};
|
|
190
|
+
export interface StepStreamOptions {
|
|
191
|
+
initialCount: number;
|
|
192
|
+
}
|
|
193
|
+
export interface StepOptions {
|
|
194
|
+
stream: StepStreamOptions | null;
|
|
195
|
+
}
|
|
196
|
+
export interface StepOptimizeOptions {
|
|
197
|
+
stream: StepStreamOptions | null;
|
|
198
|
+
}
|
|
199
|
+
export declare type GrafastSubscriber<TTopics extends {
|
|
200
|
+
[key: string]: any;
|
|
201
|
+
} = {
|
|
202
|
+
[key: string]: any;
|
|
203
|
+
}> = {
|
|
204
|
+
subscribe<TTopic extends keyof TTopics = keyof TTopics>(topic: TTopic): AsyncIterableIterator<TTopics[TTopic]>;
|
|
205
|
+
};
|
|
206
|
+
export interface NodeIdCodec<T = any> {
|
|
207
|
+
encode(value: T): string | null;
|
|
208
|
+
decode(value: string): T;
|
|
209
|
+
}
|
|
210
|
+
export declare type NodeIdHandler<TCodecs extends {
|
|
211
|
+
[key: string]: NodeIdCodec<any>;
|
|
212
|
+
} = {
|
|
213
|
+
[key: string]: NodeIdCodec<any>;
|
|
214
|
+
}, TCodecName extends keyof TCodecs = keyof TCodecs, TNodeStep extends ExecutableStep<any> = ExecutableStep<any>, TSpec = any> = {
|
|
215
|
+
typeName: string;
|
|
216
|
+
codecName: TCodecName & string;
|
|
217
|
+
match(specifier: TCodecs[TCodecName] extends NodeIdCodec<infer U> ? U : any): boolean;
|
|
218
|
+
plan($thing: TNodeStep): ExecutableStep<TCodecs[TCodecName] extends NodeIdCodec<infer U> ? U : any>;
|
|
219
|
+
getSpec(plan: ExecutableStep<TCodecs[TCodecName] extends NodeIdCodec<infer U> ? U : any>): TSpec;
|
|
220
|
+
get(spec: TSpec): TNodeStep;
|
|
221
|
+
deprecationReason?: string;
|
|
222
|
+
};
|
|
223
|
+
export declare type BaseEventMap = Record<string, any>;
|
|
224
|
+
export declare type EventMapKey<TEventMap extends BaseEventMap> = string & keyof TEventMap;
|
|
225
|
+
export declare type EventCallback<TPayload> = (params: TPayload) => void;
|
|
226
|
+
export interface TypedEventEmitter<TEventMap extends BaseEventMap> extends EventEmitter<any, any> {
|
|
227
|
+
addListener<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, callback: EventCallback<TEventMap[TEventName]>): this;
|
|
228
|
+
on<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, callback: EventCallback<TEventMap[TEventName]>): this;
|
|
229
|
+
once<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, callback: EventCallback<TEventMap[TEventName]>): this;
|
|
230
|
+
removeListener<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, callback: EventCallback<TEventMap[TEventName]>): this;
|
|
231
|
+
off<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, callback: EventCallback<TEventMap[TEventName]>): this;
|
|
232
|
+
emit<TEventName extends EventMapKey<TEventMap>>(eventName: TEventName, params: TEventMap[TEventName]): boolean;
|
|
233
|
+
}
|
|
234
|
+
export declare type ExecutionEventMap = {
|
|
235
|
+
explainOperation: {
|
|
236
|
+
operation: Record<string, any> & {
|
|
237
|
+
type: string;
|
|
238
|
+
title: string;
|
|
239
|
+
};
|
|
240
|
+
};
|
|
241
|
+
};
|
|
242
|
+
export declare type ExecutionEventEmitter = TypedEventEmitter<ExecutionEventMap>;
|
|
243
|
+
export interface ExecutionExtra {
|
|
244
|
+
meta: Record<string, unknown>;
|
|
245
|
+
eventEmitter: ExecutionEventEmitter | undefined;
|
|
246
|
+
_bucket: Bucket;
|
|
247
|
+
_requestContext: RequestContext;
|
|
248
|
+
}
|
|
249
|
+
export interface LocationDetails {
|
|
250
|
+
node: ASTNode | readonly ASTNode[];
|
|
251
|
+
parentTypeName: string | null;
|
|
252
|
+
fieldName: string | null;
|
|
253
|
+
}
|
|
254
|
+
export declare type JSONValue = boolean | number | string | null | JSONObject | JSONArray;
|
|
255
|
+
export interface JSONObject {
|
|
256
|
+
[key: string]: JSONValue;
|
|
257
|
+
}
|
|
258
|
+
export interface JSONArray extends Array<JSONValue> {
|
|
259
|
+
}
|
|
260
|
+
export {};
|
|
261
|
+
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import type { GraphQLFieldResolver, GraphQLScalarLiteralParser, GraphQLScalarSerializer, GraphQLScalarValueParser, GraphQLSchema } from "graphql";
|
|
2
|
+
import type { ArgumentApplyPlanResolver, ArgumentInputPlanResolver, EnumValueApplyPlanResolver, FieldPlanResolver, InputObjectFieldApplyPlanResolver, InputObjectFieldInputPlanResolver, ScalarPlanResolver } from "./interfaces.js";
|
|
3
|
+
import type { ExecutableStep } from "./step.js";
|
|
4
|
+
export declare type FieldPlans = FieldPlanResolver<any, any, any> | {
|
|
5
|
+
plan?: FieldPlanResolver<any, any, any>;
|
|
6
|
+
subscribePlan?: FieldPlanResolver<any, any, any>;
|
|
7
|
+
resolve?: GraphQLFieldResolver<any, any>;
|
|
8
|
+
subscribe?: GraphQLFieldResolver<any, any>;
|
|
9
|
+
args?: {
|
|
10
|
+
[argName: string]: {
|
|
11
|
+
input?: ArgumentInputPlanResolver;
|
|
12
|
+
apply?: ArgumentApplyPlanResolver;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
export declare type ObjectPlans = {
|
|
17
|
+
__Step?: {
|
|
18
|
+
new (...args: any[]): ExecutableStep<any>;
|
|
19
|
+
};
|
|
20
|
+
} & {
|
|
21
|
+
[fieldName: string]: FieldPlans;
|
|
22
|
+
};
|
|
23
|
+
export declare type InputObjectPlans = {
|
|
24
|
+
[fieldName: string]: {
|
|
25
|
+
input: InputObjectFieldInputPlanResolver;
|
|
26
|
+
apply: InputObjectFieldApplyPlanResolver;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
export declare type InterfaceOrUnionPlans = {
|
|
30
|
+
__resolveType?: (o: unknown) => string;
|
|
31
|
+
};
|
|
32
|
+
export declare type ScalarPlans = {
|
|
33
|
+
serialize?: GraphQLScalarSerializer<any>;
|
|
34
|
+
parseValue?: GraphQLScalarValueParser<any>;
|
|
35
|
+
parseLiteral?: GraphQLScalarLiteralParser<any>;
|
|
36
|
+
plan?: ScalarPlanResolver<any, any>;
|
|
37
|
+
};
|
|
38
|
+
export declare type EnumPlans = {
|
|
39
|
+
[enumValueName: string]: EnumValueApplyPlanResolver | string | number | boolean | {
|
|
40
|
+
value?: unknown;
|
|
41
|
+
apply?: EnumValueApplyPlanResolver;
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
export interface GrafastPlans {
|
|
45
|
+
[typeName: string]: ObjectPlans | InputObjectPlans | InterfaceOrUnionPlans | ScalarPlans | EnumPlans;
|
|
46
|
+
}
|
|
47
|
+
export declare function makeGrafastSchema(details: {
|
|
48
|
+
typeDefs: string;
|
|
49
|
+
plans: GrafastPlans;
|
|
50
|
+
enableDeferStream: boolean;
|
|
51
|
+
}): GraphQLSchema;
|
|
52
|
+
//# sourceMappingURL=makeGrafastSchema.d.ts.map
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { OperationPlan } from ".";
|
|
2
|
+
import type { ExecutableStep } from "./step.js";
|
|
3
|
+
export declare const COLORS: string[];
|
|
4
|
+
export declare const mermaidEscape: (str: string) => string;
|
|
5
|
+
export interface PrintPlanGraphOptions {
|
|
6
|
+
printPathRelations?: boolean;
|
|
7
|
+
includePaths?: boolean;
|
|
8
|
+
concise?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare function printPlanGraph(operationPlan: OperationPlan, { concise, }: PrintPlanGraphOptions, { steps, }: {
|
|
11
|
+
steps: {
|
|
12
|
+
[stepId: number]: ExecutableStep;
|
|
13
|
+
};
|
|
14
|
+
}): string;
|
|
15
|
+
//# sourceMappingURL=mermaid.d.ts.map
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { GraphQLField } from "graphql";
|
|
2
|
+
import type { OperationPlan } from "./engine/OperationPlan.js";
|
|
3
|
+
import type { FieldArgs, TrackedArguments } from "./interfaces.js";
|
|
4
|
+
import { ExecutableStep } from "./step.js";
|
|
5
|
+
export declare function withFieldArgsForArguments<T extends ExecutableStep, TParentStep extends ExecutableStep<any> = ExecutableStep<any>>(operationPlan: OperationPlan, parentPlan: TParentStep, $all: TrackedArguments, field: GraphQLField<any, any, any>, callback: (fieldArgs: FieldArgs) => T | null | undefined): Exclude<T, undefined | null | void> | TParentStep;
|
|
6
|
+
//# sourceMappingURL=opPlan-input.d.ts.map
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { PolymorphicData } from "./interfaces.js";
|
|
2
|
+
export declare function isPolymorphicData(data: unknown): data is PolymorphicData;
|
|
3
|
+
export declare function assertPolymorphicData(data: unknown): asserts data is PolymorphicData;
|
|
4
|
+
export declare function polymorphicWrap<TType extends string>(type: TType, data?: unknown): PolymorphicData<TType>;
|
|
5
|
+
export declare function resolveType(o: unknown): string;
|
|
6
|
+
//# sourceMappingURL=polymorphic.d.ts.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { ExecutionArgs } from "graphql";
|
|
2
|
+
import type { AsyncExecutionResult, ExecutionResult } from "graphql/execution/execute";
|
|
3
|
+
import type { OperationPlan } from "./index.js";
|
|
4
|
+
import type { PromiseOrDirect } from "./interfaces.js";
|
|
5
|
+
export interface GrafastPrepareOptions {
|
|
6
|
+
explain?: boolean | string[];
|
|
7
|
+
asString?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function executePreemptive(operationPlan: OperationPlan, variableValues: any, context: any, rootValue: any, asString: boolean): PromiseOrDirect<ExecutionResult | AsyncGenerator<AsyncExecutionResult, void, void>>;
|
|
10
|
+
export declare function grafastPrepare(args: ExecutionArgs, options?: GrafastPrepareOptions): PromiseOrDirect<ExecutionResult | AsyncGenerator<AsyncExecutionResult, void, void>>;
|
|
11
|
+
//# sourceMappingURL=prepare.d.ts.map
|
package/dist/step.d.ts
ADDED
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import type { GraphQLObjectType } from "graphql";
|
|
2
|
+
import type { LayerPlan } from "./engine/LayerPlan.js";
|
|
3
|
+
import type { OperationPlan } from "./engine/OperationPlan.js";
|
|
4
|
+
import type { ExecutionExtra, GrafastResultsList, GrafastResultStreamList, GrafastValuesList, PromiseOrDirect, StepOptimizeOptions, StepOptions } from "./interfaces.js";
|
|
5
|
+
import type { __ItemStep } from "./steps/index.js";
|
|
6
|
+
export declare const $$deepDepSkip: unique symbol;
|
|
7
|
+
export declare const $$noExec: unique symbol;
|
|
8
|
+
declare function reallyAssertFinalized(plan: BaseStep): void;
|
|
9
|
+
export declare const assertFinalized: typeof reallyAssertFinalized;
|
|
10
|
+
export declare abstract class BaseStep {
|
|
11
|
+
readonly layerPlan: LayerPlan;
|
|
12
|
+
readonly opPlan: OperationPlan;
|
|
13
|
+
isArgumentsFinalized: boolean;
|
|
14
|
+
isFinalized: boolean;
|
|
15
|
+
debug: boolean;
|
|
16
|
+
hasSideEffects: boolean;
|
|
17
|
+
constructor();
|
|
18
|
+
toString(): string;
|
|
19
|
+
toStringMeta(): string | null;
|
|
20
|
+
finalize(): void;
|
|
21
|
+
destroy(): void;
|
|
22
|
+
}
|
|
23
|
+
export declare class ExecutableStep<TData = any> extends BaseStep {
|
|
24
|
+
static $$export: any;
|
|
25
|
+
isSyncAndSafe: boolean;
|
|
26
|
+
readonly dependencies: ReadonlyArray<ExecutableStep>;
|
|
27
|
+
readonly dependents: ReadonlyArray<{
|
|
28
|
+
step: ExecutableStep;
|
|
29
|
+
dependencyIndex: number;
|
|
30
|
+
}>;
|
|
31
|
+
readonly id: number;
|
|
32
|
+
isOptimized: boolean;
|
|
33
|
+
allowMultipleOptimizations: boolean;
|
|
34
|
+
_stepOptions: StepOptions;
|
|
35
|
+
polymorphicPaths: ReadonlySet<string>;
|
|
36
|
+
store: boolean;
|
|
37
|
+
metaKey: number | string | symbol;
|
|
38
|
+
constructor();
|
|
39
|
+
protected withMyLayerPlan<T>(callback: () => T): T;
|
|
40
|
+
protected getStep(id: number): ExecutableStep;
|
|
41
|
+
getDep(depId: number): ExecutableStep;
|
|
42
|
+
protected getDepDeep(depId: number): ExecutableStep;
|
|
43
|
+
toString(): string;
|
|
44
|
+
protected addDependency(step: ExecutableStep, skipDeduplication?: boolean): number;
|
|
45
|
+
deduplicate(_peers: readonly ExecutableStep[]): readonly ExecutableStep[];
|
|
46
|
+
deduplicatedWith(replacement: ExecutableStep): void;
|
|
47
|
+
optimize(_options: StepOptimizeOptions): ExecutableStep;
|
|
48
|
+
finalize(): void;
|
|
49
|
+
execute(values: ReadonlyArray<GrafastValuesList<any>>, extra: ExecutionExtra): PromiseOrDirect<GrafastResultsList<TData>>;
|
|
50
|
+
destroy(): void;
|
|
51
|
+
}
|
|
52
|
+
export declare abstract class UnbatchedExecutableStep<TData = any> extends ExecutableStep<TData> {
|
|
53
|
+
static $$export: {
|
|
54
|
+
moduleName: string;
|
|
55
|
+
exportName: string;
|
|
56
|
+
};
|
|
57
|
+
finalize(): void;
|
|
58
|
+
execute(values: ReadonlyArray<GrafastValuesList<any>>, extra: ExecutionExtra): PromiseOrDirect<GrafastResultsList<TData>>;
|
|
59
|
+
abstract unbatchedExecute(extra: ExecutionExtra, ...tuple: any[]): PromiseOrDirect<TData>;
|
|
60
|
+
}
|
|
61
|
+
export declare function isExecutableStep<TData = any>(step: unknown): step is ExecutableStep<TData>;
|
|
62
|
+
export declare function assertExecutableStep<TData>(step: BaseStep): asserts step is ExecutableStep<TData>;
|
|
63
|
+
export declare function isUnbatchedExecutableStep<TData = any>(step: unknown): step is UnbatchedExecutableStep<TData>;
|
|
64
|
+
export declare type ObjectLikeStep<TData extends {
|
|
65
|
+
[key: string]: ExecutableStep<any>;
|
|
66
|
+
} = {
|
|
67
|
+
[key: string]: ExecutableStep<any>;
|
|
68
|
+
}> = ExecutableStep<{
|
|
69
|
+
[key in keyof TData]: TData[key] extends ExecutableStep<infer U> ? U : never;
|
|
70
|
+
}> & {
|
|
71
|
+
get<TKey extends keyof TData>(key: TKey): ExecutableStep<TData[TKey]>;
|
|
72
|
+
};
|
|
73
|
+
export declare function isObjectLikeStep<TData extends {
|
|
74
|
+
[key: string]: ExecutableStep<any>;
|
|
75
|
+
} = {
|
|
76
|
+
[key: string]: ExecutableStep<any>;
|
|
77
|
+
}>(plan: ExecutableStep): plan is ObjectLikeStep<TData>;
|
|
78
|
+
export declare type StreamableStep<TData> = ExecutableStep<ReadonlyArray<TData>> & {
|
|
79
|
+
stream(values: ReadonlyArray<GrafastValuesList<any>>, extra: ExecutionExtra, streamOptions: {
|
|
80
|
+
initialCount: number;
|
|
81
|
+
}): PromiseOrDirect<GrafastResultStreamList<TData>>;
|
|
82
|
+
};
|
|
83
|
+
export declare function isStreamableStep<TData>(plan: ExecutableStep<ReadonlyArray<TData>>): plan is StreamableStep<TData>;
|
|
84
|
+
export declare type PolymorphicStep = ExecutableStep & {
|
|
85
|
+
planForType(objectType: GraphQLObjectType): ExecutableStep;
|
|
86
|
+
};
|
|
87
|
+
export declare function isPolymorphicStep(s: ExecutableStep): s is PolymorphicStep;
|
|
88
|
+
export declare abstract class ModifierStep<TParentStep extends BaseStep = BaseStep> extends BaseStep {
|
|
89
|
+
protected readonly $parent: TParentStep;
|
|
90
|
+
static $$export: any;
|
|
91
|
+
readonly id: string;
|
|
92
|
+
constructor($parent: TParentStep);
|
|
93
|
+
toString(): string;
|
|
94
|
+
abstract apply(): void;
|
|
95
|
+
}
|
|
96
|
+
export declare function isModifierStep<TParentStep extends ExecutableStep | ModifierStep<any>>(plan: BaseStep): plan is ModifierStep<TParentStep>;
|
|
97
|
+
export declare function assertModifierStep<TParentStep extends ExecutableStep | ModifierStep<any>>(plan: BaseStep, pathDescription: string): asserts plan is ModifierStep<TParentStep>;
|
|
98
|
+
export interface ListCapableStep<TOutputData, TItemStep extends ExecutableStep<TOutputData> = ExecutableStep<TOutputData>> extends ExecutableStep<ReadonlyArray<any>> {
|
|
99
|
+
listItem(itemPlan: __ItemStep<this>): TItemStep;
|
|
100
|
+
}
|
|
101
|
+
export declare function isListCapableStep<TData, TItemStep extends ExecutableStep<TData>>(plan: ExecutableStep<ReadonlyArray<TData>>): plan is ListCapableStep<TData, TItemStep>;
|
|
102
|
+
export declare function assertListCapableStep<TData, TItemStep extends ExecutableStep<TData>>(plan: ExecutableStep<ReadonlyArray<TData>>, pathDescription: string): asserts plan is ListCapableStep<TData, TItemStep>;
|
|
103
|
+
export {};
|
|
104
|
+
//# sourceMappingURL=step.d.ts.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { AsyncExecutionResult, ExecutionArgs, ExecutionResult } from "graphql";
|
|
2
|
+
import type { PromiseOrValue } from "graphql/jsutils/PromiseOrValue";
|
|
3
|
+
export declare function subscribe(args: ExecutionArgs, resolvedPreset?: GraphileConfig.ResolvedPreset, asString?: boolean): PromiseOrValue<AsyncGenerator<ExecutionResult | AsyncExecutionResult, void, void> | ExecutionResult>;
|
|
4
|
+
//# sourceMappingURL=subscribe.d.ts.map
|
package/dist/utils.d.ts
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import type { FieldNode, GraphQLEnumValueConfig, GraphQLFieldConfig, GraphQLInputFieldConfig, GraphQLInputObjectTypeConfig, GraphQLInputType, GraphQLNamedType, GraphQLObjectTypeConfig, GraphQLOutputType, GraphQLSchema, ValueNode } from "graphql";
|
|
2
|
+
import { GraphQLEnumType, GraphQLInputObjectType, GraphQLObjectType } from "graphql";
|
|
3
|
+
import type { Deferred } from "./deferred.js";
|
|
4
|
+
import type { OperationPlan } from "./engine/OperationPlan.js";
|
|
5
|
+
import type { InputStep } from "./input.js";
|
|
6
|
+
import type { BaseGraphQLArguments, BaseGraphQLContext, GraphileFieldConfig, GraphileInputFieldConfig, OutputPlanForType } from "./interfaces.js";
|
|
7
|
+
import type { ExecutableStep, ModifierStep } from "./step.js";
|
|
8
|
+
export declare const ROOT_VALUE_OBJECT: any;
|
|
9
|
+
export declare function assertNullPrototype(object: Record<string, unknown>, description: string): void;
|
|
10
|
+
export declare function defaultValueToValueNode(type: GraphQLInputType, defaultValue: unknown): ValueNode | undefined;
|
|
11
|
+
export declare function isPromise<T>(t: T | Promise<T>): t is Promise<T>;
|
|
12
|
+
export declare function isPromiseLike<T>(t: T | Promise<T> | PromiseLike<T>): t is PromiseLike<T>;
|
|
13
|
+
export declare function isDeferred<T>(t: T | Promise<T> | Deferred<T>): t is Deferred<T>;
|
|
14
|
+
export declare function arraysMatch<T>(array1: ReadonlyArray<T>, array2: ReadonlyArray<T>, comparator?: (val1: T, val2: T) => boolean): boolean;
|
|
15
|
+
export declare type ObjectTypeFields<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>> = {
|
|
16
|
+
[key: string]: GraphileFieldConfig<GraphQLOutputType, TContext, TParentStep, any, any>;
|
|
17
|
+
};
|
|
18
|
+
export declare type ObjectTypeSpec<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>, TFields extends ObjectTypeFields<TContext, TParentStep>> = Omit<GraphQLObjectTypeConfig<any, TContext>, "fields"> & {
|
|
19
|
+
fields: TFields | (() => TFields);
|
|
20
|
+
};
|
|
21
|
+
export declare function objectSpec<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>, TFields extends ObjectTypeFields<TContext, TParentStep>>(spec: ObjectTypeSpec<TContext, TParentStep, TFields>, Step: {
|
|
22
|
+
new (...args: any[]): TParentStep;
|
|
23
|
+
} | null): GraphQLObjectTypeConfig<any, TContext>;
|
|
24
|
+
export declare type GraphileObjectType<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>, TFields extends ObjectTypeFields<TContext, TParentStep>> = GraphQLObjectType<TParentStep extends ExecutableStep<infer U> ? U : never, TContext> & {
|
|
25
|
+
TParentStep: TParentStep;
|
|
26
|
+
TFields: TFields;
|
|
27
|
+
};
|
|
28
|
+
export declare function newObjectTypeBuilder<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>>(Step: {
|
|
29
|
+
new (...args: any[]): TParentStep;
|
|
30
|
+
}): <TFields extends ObjectTypeFields<TContext, TParentStep>>(spec: ObjectTypeSpec<TContext, TParentStep, TFields>) => GraphileObjectType<TContext, TParentStep, TFields>;
|
|
31
|
+
export declare function objectFieldSpec<TContext extends BaseGraphQLContext, TSource extends ExecutableStep<any>, TResult extends ExecutableStep<any> = ExecutableStep<any>, TArgs extends BaseGraphQLArguments = BaseGraphQLArguments>(graphileSpec: GraphileFieldConfig<GraphQLOutputType, TContext, TSource, TResult, TArgs>): GraphQLFieldConfig<any, TContext, TArgs>;
|
|
32
|
+
export declare function newGraphileFieldConfigBuilder<TContext extends BaseGraphQLContext, TParentStep extends ExecutableStep<any>>(): <TType extends GraphQLOutputType, TFieldStep extends OutputPlanForType<TType>, TArgs extends BaseGraphQLArguments>(config: GraphileFieldConfig<TType, TContext, TParentStep, TFieldStep, TArgs>) => typeof config;
|
|
33
|
+
export declare type GraphileInputFieldConfigMap<TContext extends BaseGraphQLContext, TParentStep extends ModifierStep<any>> = {
|
|
34
|
+
[key: string]: GraphileInputFieldConfig<GraphQLInputType, TContext, TParentStep, any, any>;
|
|
35
|
+
};
|
|
36
|
+
export declare type InputObjectTypeSpec<TContext extends BaseGraphQLContext, TParentStep extends ModifierStep<any>, TFields extends GraphileInputFieldConfigMap<TContext, TParentStep>> = Omit<GraphQLInputObjectTypeConfig, "fields"> & {
|
|
37
|
+
fields: TFields | (() => TFields);
|
|
38
|
+
};
|
|
39
|
+
export declare type GraphileInputObjectType<TContext extends BaseGraphQLContext, TParentStep extends ModifierStep<any>, TFields extends GraphileInputFieldConfigMap<TContext, TParentStep>> = GraphQLInputObjectType & {
|
|
40
|
+
TContext: TContext;
|
|
41
|
+
TParentStep: TParentStep;
|
|
42
|
+
TFields: TFields;
|
|
43
|
+
};
|
|
44
|
+
export declare function newInputObjectTypeBuilder<TContext extends BaseGraphQLContext, TParentStep extends ModifierStep<any>>(): <TFields extends GraphileInputFieldConfigMap<TContext, TParentStep>>(spec: InputObjectTypeSpec<TContext, TParentStep, TFields>) => GraphileInputObjectType<TContext, TParentStep, TFields>;
|
|
45
|
+
export declare function inputObjectFieldSpec<TContext extends BaseGraphQLContext, TParent extends ModifierStep<any>, TResult extends ModifierStep<TParent> = ModifierStep<TParent>, TInput extends InputStep = InputStep>(graphileSpec: GraphileInputFieldConfig<GraphQLInputType, TContext, TParent, TResult, TInput>): GraphQLInputFieldConfig;
|
|
46
|
+
export declare function getEnumValueConfig(enumType: GraphQLEnumType, outputValue: unknown): GraphQLEnumValueConfig | undefined;
|
|
47
|
+
export declare const sharedNull: any;
|
|
48
|
+
export declare function stack(message: string, length?: number): void;
|
|
49
|
+
export declare function arrayOfLength(length: number, fill?: any): any[];
|
|
50
|
+
export declare function arrayOfLengthCb(length: number, fill: () => any): any[];
|
|
51
|
+
export declare function findVariableNamesUsed(operationPlan: OperationPlan, field: FieldNode): string[];
|
|
52
|
+
export declare function isTypePlanned(schema: GraphQLSchema, namedType: GraphQLNamedType): boolean;
|
|
53
|
+
export declare function stepADependsOnStepB(stepA: ExecutableStep, stepB: ExecutableStep): boolean;
|
|
54
|
+
export declare function stepAMayDependOnStepB($a: ExecutableStep, $b: ExecutableStep): boolean;
|
|
55
|
+
export declare function stepsAreInSamePhase(ancestor: ExecutableStep, descendent: ExecutableStep): boolean;
|
|
56
|
+
export declare const canonicalJSONStringify: (o: object) => string;
|
|
57
|
+
export declare const isSafeObjectPropertyName: (key: string) => boolean;
|
|
58
|
+
export declare const canRepresentAsIdentifier: (key: string) => boolean;
|
|
59
|
+
export declare const evalSafeProperty: (key: string) => string;
|
|
60
|
+
//# sourceMappingURL=utils.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,14 +1,65 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "grafast",
|
|
3
|
-
"version": "0.0.0",
|
|
4
|
-
"description": "
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"
|
|
7
|
-
|
|
3
|
+
"version": "0.0.1-0.1",
|
|
4
|
+
"description": "Cutting edge GraphQL planning and execution engine",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/index.d.ts",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"types": "./dist/index.d.ts",
|
|
10
|
+
"node": "./dist/index.js",
|
|
11
|
+
"default": "./dist/index.js"
|
|
12
|
+
},
|
|
13
|
+
"./envelop": {
|
|
14
|
+
"types": "./dist/envelop.d.ts",
|
|
15
|
+
"node": "./dist/envelop.js",
|
|
16
|
+
"default": "./dist/envelop.js"
|
|
17
|
+
}
|
|
8
18
|
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "git+https://github.com/graphile/heart.git"
|
|
22
|
+
},
|
|
23
|
+
"keywords": [
|
|
24
|
+
"grafast",
|
|
25
|
+
"graphile",
|
|
26
|
+
"graphql",
|
|
27
|
+
"performance",
|
|
28
|
+
"fast",
|
|
29
|
+
"engine",
|
|
30
|
+
"graphqljs",
|
|
31
|
+
"execute",
|
|
32
|
+
"plan",
|
|
33
|
+
"planning",
|
|
34
|
+
"grafast",
|
|
35
|
+
"dataplanner",
|
|
36
|
+
"graphite"
|
|
37
|
+
],
|
|
9
38
|
"author": "Benjie Gillam <code@benjiegillam.com>",
|
|
10
|
-
"license": "
|
|
39
|
+
"license": "SEE LICENSE IN LICENSE.md",
|
|
40
|
+
"bugs": {
|
|
41
|
+
"url": "https://github.com/graphile/heart/issues"
|
|
42
|
+
},
|
|
43
|
+
"homepage": "https://grafast.org",
|
|
44
|
+
"engines": {
|
|
45
|
+
"node": ">=14.17"
|
|
46
|
+
},
|
|
47
|
+
"dependencies": {
|
|
48
|
+
"@graphile/lru": "^5.0.0-0.1"
|
|
49
|
+
},
|
|
50
|
+
"peerDependencies": {
|
|
51
|
+
"graphile-config": "^0.0.1-0.0",
|
|
52
|
+
"graphql": "*"
|
|
53
|
+
},
|
|
54
|
+
"peerDependenciesMeta": {
|
|
55
|
+
"graphile-config": {
|
|
56
|
+
"optional": true
|
|
57
|
+
}
|
|
58
|
+
},
|
|
11
59
|
"files": [
|
|
12
|
-
"
|
|
13
|
-
]
|
|
14
|
-
|
|
60
|
+
"dist"
|
|
61
|
+
],
|
|
62
|
+
"publishConfig": {
|
|
63
|
+
"access": "public"
|
|
64
|
+
}
|
|
65
|
+
}
|
package/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
console.log('Grafast is coming soon!')
|