@graphql-tools/stitching-directives 2.1.1-alpha-db7f3b43.0 → 3.0.0-alpha-24ba9af0.0

Sign up to get free protection for your applications and to get access to all the features.
package/es5/package.json DELETED
@@ -1,36 +0,0 @@
1
- {
2
- "name": "@graphql-tools/stitching-directives/es5",
3
- "version": "2.1.1-alpha-db7f3b43.0",
4
- "description": "A set of utils for faster development of GraphQL tools",
5
- "sideEffects": false,
6
- "peerDependencies": {
7
- "graphql": "^14.0.0 || ^15.0.0 || ^16.0.0"
8
- },
9
- "dependencies": {
10
- "@graphql-tools/delegate": "8.2.2-alpha-db7f3b43.0",
11
- "@graphql-tools/utils": "^8.2.0",
12
- "tslib": "~2.3.0"
13
- },
14
- "repository": {
15
- "type": "git",
16
- "url": "ardatan/graphql-tools",
17
- "directory": "packages/stitching-directives"
18
- },
19
- "license": "MIT",
20
- "main": "index.js",
21
- "module": "index.mjs",
22
- "typings": "index.d.ts",
23
- "typescript": {
24
- "definition": "index.d.ts"
25
- },
26
- "exports": {
27
- ".": {
28
- "require": "./index.js",
29
- "import": "./index.mjs"
30
- },
31
- "./*": {
32
- "require": "./*.js",
33
- "import": "./*.mjs"
34
- }
35
- }
36
- }
@@ -1,3 +0,0 @@
1
- import { SelectionSetNode } from 'graphql';
2
- import { ParsedMergeArgsExpr } from './types';
3
- export declare function parseMergeArgsExpr(mergeArgsExpr: string, selectionSet?: SelectionSetNode): ParsedMergeArgsExpr;
@@ -1,2 +0,0 @@
1
- import { SelectionSetNode } from 'graphql';
2
- export declare function pathsFromSelectionSet(selectionSet: SelectionSetNode, path?: Array<string>): Array<Array<string>>;
@@ -1,6 +0,0 @@
1
- export declare const KEY_DELIMITER = "__dot__";
2
- export declare const EXPANSION_PREFIX = "__exp";
3
- export declare function preparseMergeArgsExpr(mergeArgsExpr: string): {
4
- mergeArgsExpr: string;
5
- expansionExpressions: Record<string, string>;
6
- };
@@ -1,5 +0,0 @@
1
- import { PropertyTree } from './types';
2
- export declare function addProperty(object: Record<string, any>, path: Array<string | number>, value: any): void;
3
- export declare function getProperty(object: Record<string, any>, path: Array<string>): any;
4
- export declare function getProperties(object: Record<string, any>, propertyTree: PropertyTree): any;
5
- export declare function propertyTreeFromPaths(paths: Array<Array<string>>): PropertyTree;
@@ -1,18 +0,0 @@
1
- import { GraphQLDirective, GraphQLSchema } from 'graphql';
2
- import { SubschemaConfig } from '@graphql-tools/delegate';
3
- import { StitchingDirectivesOptions } from './types';
4
- export declare function stitchingDirectives(options?: StitchingDirectivesOptions): {
5
- keyDirectiveTypeDefs: string;
6
- computedDirectiveTypeDefs: string;
7
- mergeDirectiveTypeDefs: string;
8
- canonicalDirectiveTypeDefs: string;
9
- stitchingDirectivesTypeDefs: string;
10
- allStitchingDirectivesTypeDefs: string;
11
- stitchingDirectivesValidator: (schema: GraphQLSchema) => GraphQLSchema;
12
- stitchingDirectivesTransformer: (subschemaConfig: SubschemaConfig) => SubschemaConfig;
13
- keyDirective: GraphQLDirective;
14
- computedDirective: GraphQLDirective;
15
- mergeDirective: GraphQLDirective;
16
- canonicalDirective: GraphQLDirective;
17
- allStitchingDirectives: Array<GraphQLDirective>;
18
- };
@@ -1,3 +0,0 @@
1
- import { SubschemaConfig } from '@graphql-tools/delegate';
2
- import { StitchingDirectivesOptions } from './types';
3
- export declare function stitchingDirectivesTransformer(options?: StitchingDirectivesOptions): (subschemaConfig: SubschemaConfig) => SubschemaConfig;
@@ -1,3 +0,0 @@
1
- import { GraphQLSchema } from 'graphql';
2
- import { StitchingDirectivesOptions } from './types';
3
- export declare function stitchingDirectivesValidator(options?: StitchingDirectivesOptions): (schema: GraphQLSchema) => GraphQLSchema;
package/es5/types.d.ts DELETED
@@ -1,35 +0,0 @@
1
- export interface PropertyTree {
2
- [property: string]: null | PropertyTree;
3
- }
4
- export interface ParsedMergeArgsExpr {
5
- args: Record<string, any>;
6
- usedProperties: PropertyTree;
7
- mappingInstructions?: Array<MappingInstruction>;
8
- expansions?: Array<Expansion>;
9
- }
10
- export interface MappingInstruction {
11
- destinationPath: Array<string>;
12
- sourcePath: Array<string>;
13
- }
14
- export interface Expansion {
15
- valuePath: Array<string>;
16
- value: any;
17
- mappingInstructions: Array<MappingInstruction>;
18
- }
19
- export declare type VariablePaths = Record<string, Array<string | number>>;
20
- export interface StitchingDirectivesOptions {
21
- keyDirectiveName?: string;
22
- computedDirectiveName?: string;
23
- mergeDirectiveName?: string;
24
- canonicalDirectiveName?: string;
25
- pathToDirectivesInExtensions?: Array<string>;
26
- }
27
- declare type Complete<T> = {
28
- [P in keyof Required<T>]: Exclude<Pick<T, P> extends Required<Pick<T, P>> ? T[P] : T[P] | undefined, undefined>;
29
- };
30
- export declare type StitchingDirectivesFinalOptions = Complete<StitchingDirectivesOptions>;
31
- export interface MergedTypeResolverInfo extends ParsedMergeArgsExpr {
32
- fieldName: string;
33
- returnsList: boolean;
34
- }
35
- export {};