Skip to content

Commit

Permalink
Merge pull request #3 from theGlenn/develop
Browse files Browse the repository at this point in the history
1.0.4
  • Loading branch information
theGlenn authored May 31, 2018
2 parents c413f4b + 4cd868f commit 737547b
Show file tree
Hide file tree
Showing 19 changed files with 45 additions and 59 deletions.
11 changes: 11 additions & 0 deletions dist/resolvers/Chainable.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { ResolverFunction, Resolvers, ChainedFunction } from './resolvers.types';
export interface ChainableArgs<EndResult> {
before: ResolverFunction<any>;
next: ResolverFunction<EndResult>;
}
export default class Chainable<ChainResult> {
private resolver;
constructor(resolver: ResolverFunction<ChainResult>);
after<T>(resolversToApply: Resolvers): ChainedFunction<T>;
static assemble<R>({before, next}: ChainableArgs<R>): ChainedFunction<R>;
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions dist/resolvers/Chainable.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/resolvers/apis/apply.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/resolvers/apis/chain.d.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
import { ResolverFunction, ResolverChained } from './../resolvers.types';
export declare const chain: <R>(resolvers: ResolverFunction<any>[]) => ResolverChained<any> | ResolverChained<R>;
import { ResolverFunction, ChainedFunction } from './../resolvers.types';
export declare const chain: <R>(resolvers: ResolverFunction<any>[]) => ChainedFunction<any> | ChainedFunction<R>;
4 changes: 2 additions & 2 deletions dist/resolvers/apis/chain.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/resolvers/apis/chain.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/resolvers/apis/protect.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ResolverChained, ResolverFunction, ResolversMap, Resolvers } from './../resolvers.types';
import { ResolverFunction, ResolversMap, Resolvers, ChainedFunction } from './../resolvers.types';
export interface ProtectArgs<R> {
it?: ResolverFunction<R>;
all?: ResolversMap;
using: Resolvers;
}
export declare const protect: <R>({ it, all, using }: ProtectArgs<R>) => ResolversMap | ResolverChained<any>;
export declare const protect: <R>({ it, all, using }: ProtectArgs<R>) => ResolversMap | ChainedFunction<any>;
3 changes: 1 addition & 2 deletions dist/resolvers/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
export * from './apis';
export * from './resolvers.types';
export * from './resolvers.check';
export * from './resolvers.chain';
export * from './resolvers.assembler';
export * from './Chainable';
3 changes: 1 addition & 2 deletions dist/resolvers/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/resolvers/index.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions dist/resolvers/resolvers.assembler.d.ts

This file was deleted.

1 change: 0 additions & 1 deletion dist/resolvers/resolvers.assembler.js.map

This file was deleted.

6 changes: 0 additions & 6 deletions dist/resolvers/resolvers.chain.d.ts

This file was deleted.

19 changes: 0 additions & 19 deletions dist/resolvers/resolvers.chain.js

This file was deleted.

1 change: 0 additions & 1 deletion dist/resolvers/resolvers.chain.js.map

This file was deleted.

2 changes: 1 addition & 1 deletion dist/resolvers/resolvers.types.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
export interface ResolverFunction<Result> {
(root: any, args: {}, context: {}, info: {}): Promise<Result> | Result | never;
}
export interface ResolverChained<FinalResult> extends ResolverFunction<FinalResult | any> {
export interface ChainedFunction<FinalResult> extends ResolverFunction<FinalResult | any> {
(root: any, args: {}, context: {}, info: {}): Promise<FinalResult | any>;
}
export declare type Resolvers = Array<ResolverFunction<any>>;
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "graphql-resolved",
"version": "1.0.2",
"version": "1.0.4",
"description": "Framework agnostic resolvers creation/composition for GraphQL",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down Expand Up @@ -31,10 +31,10 @@
},
"repository": {
"type": "git",
"url": "https://github.com/theGlenn/graphql-resolvers-chain.git"
"url": "https://github.com/theGlenn/graphql-resolved.git"
},
"bugs": {
"url": "https://github.com/theGlenn/graphql-resolvers-chain/issues"
"url": "https://github.com/theGlenn/graphql-resolved/issues"
},
"homepage": "https://github.com/theGlenn/graphql-resolvers-chain"
"homepage": "https://github.com/theGlenn/graphql-resolved"
}
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
]
},
"exclude": [
"./test",
"./dist",
"./node_modules",
"./src/**/*.spec.ts",
Expand Down

0 comments on commit 737547b

Please sign in to comment.