Skip to content

encouter the type problem for plugin #2

@mpx2m

Description

@mpx2m

my dependencies as flows, and encouter the type problem

@pointblankdev/apollo-plugin-sentry": "^0.0.6",
@sentry/node": "^6.16.1",
@sentry/tracing": "^6.16.1",
"typescript": "^4.4.2"
"apollo-server-express": "^3.5.0",
"apollo-server-types": "^3.4.0",
"graphql": "^15.4.0"
Type '{ requestDidStart(_: GraphQLRequestContext<Record<string, any>>): { didEncounterErrors(ctx: GraphQLRequestContext<Record<string, any>>): void; }; }' is not assignable to type 'PluginDefinition'.
  Type '{ requestDidStart(_: GraphQLRequestContext<Record<string, any>>): { didEncounterErrors(ctx: GraphQLRequestContext<Record<string, any>>): void; }; }' is not assignable to type 'ApolloServerPlugin<BaseContext>'.
    The types returned by 'requestDidStart(...)' are incompatible between these types.
      Type '{ didEncounterErrors(ctx: GraphQLRequestContext<Record<string, any>>): void; }' is missing the following properties from type 'Promise<void | GraphQLRequestListener<BaseContext>>': then, catch, finally, [Symbol.toStringTag]ts(2322)

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions