-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Description
TypeScript Version: 3.0.3
Search Terms: graphql, GraphQLNonNull
Code
export const UserConnection = connectionDefinitions({
name: 'User',
nodeType: GraphQLNonNull(UserType),
});
// A *self-contained* demonstration of the problem follows...
// Test this by running `tsc` on the command-line, rather than through another build tool such as Gulp, Webpack, etc.
src/modules/user/UserType.ts:39:13 - error TS2348: Value of type 'typeof GraphQLNonNull' is not callable. Did you mean to include 'new'?
39 nodeType: GraphQLNonNull(UserType),
~~~~~~~~~~~~~~~~~~~~~~~~
Expected behavior:
it should be able to use GraphQLNonNull without new
keyword
Actual behavior:
it requires new
keyword
Check this for more info of this change graphql/graphql-js#1136
How can I disable this error?
Playground Link:
Related Issues:
Metadata
Metadata
Assignees
Labels
No labels