Skip to content

Cannot use ESM together with CJS -> cannot use "import" with graphql-express #2740

Closed
@schrotie

Description

@schrotie

When mixing ECMA script modules (via import) and CommonJS modules in node.js (V14.5.0) then GraphQL complains that duplicate GraphQL modules cannot be used together.

One consequence of this is that it is to my knowledge impossible to use express-graphql together with import syntax. That is seemingly because "import" pulls other code than the "require" that express-graphql will use.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions