graphql-js-wg icon indicating copy to clipboard operation
graphql-js-wg copied to clipboard

[2024-05] Field a proposal to replace `instanceof`

Open kitten opened this issue 1 year ago • 0 comments

Write a proposal to replace instanceof checks (implemented via https://github.com/graphql/graphql-js/blob/main/src/jsutils/instanceOf.ts).

These are currently used for internal schema language class instance checks and an error has been put in place to prevent two instances of the graphql package from cooperating.

This also contains a dev/prod split and check that's causing other issues.

We may want to replace this with a warning (rather than an error) to prevent breaking changes, and replace the general approach on how we identify schema language class instances with something else (what this proposal should define)

  • assignee(s): @kitten
  • source:
  • expecting to check in with: @JoviDeCroock @jerelmiller @phryneas

Note: Action Item issues are reviewed and closed during Working Group meetings.

kitten avatar May 29 '24 17:05 kitten