GraphiQL `onEditQuery` is called without query argument after TypeScript migration
See original GitHub issueI’m updating our installation of graphiql to 1.0.0-alpha.1
, and thanks to the new TypeScript types (🎉) I was was really quickly made aware that the type signature of the function passed to GraphiQL
as the onEditQuery
prop has changed:
This breaks our usage of graphiql-explorer. (see example setup which uses onEditQuery
https://github.com/OneGraph/graphiql-explorer-example/blob/master/src/App.js#L189)
It looks like this change was made in the recent TypeScript migration.
I understand that this prop is likely going to be deprecated in the new API per #1165, but it looks to me like this change was unintentional (onEditQuery
is unchanged in the README, and per https://github.com/graphql/graphiql/pull/1242#issue-364380842 that this should have minimal production changes).
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (5 by maintainers)
Top GitHub Comments
great! thanks for this, we can get another alpha out here shortly. I’ll close this once it’s been released. glad the new typescript types are working out for you 😄
use latest alpha btw! @cshaver lemme know if you have any issues