Skip to content

[zod-graphql-query-builder] Type instantiation is excessively deep and possibly infinite #285

@jjclxrk

Description

@jjclxrk

Trying out this package, have copied the first basic example from the README and am getting a typescript error:

Type instantiation is excessively deep and possibly infinite. (2589)

Example reproduction in Typescript playground:

https://www.typescriptlang.org/play/?#code/JYWwDg9gTgLgBAKjgQwM5wF5wGZQiOAIgwgBNCBuAKFEljgG84AjAV2ABtSBxKZMABYBHDgEVWAUygBPOAF8ceAoQACqAMYCJIZAFoBrZgHoSpXQHM+gkbqGSZutp1JTKVKuogA7VPBgTfAGVNbWQ4AF5MADoIZgArCXUYAAombAgIAC5o3yhgL3NkgEp5Iqjc4CTi6g9vXzh-X3EpWUinLl5+YTF7aWTGmGCtHSKazx8IDgkojghCgeaZUaA

Is there a suggested approach to resolving this issue? The code runs and produces the expected output, but ideally typescript wouldn't be flagging issues everywhere I need to call the buildGraphqlQuery function.

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