RFC: Provide codemods to/from GraphQL Code Generator’s client-preset
[Strawman]
#95
Labels
future 🔮
An enhancement or feature proposal that will be addressed after the next release
Important
This is a strawman RFC.
It's a very early thought that has come up, but documenting it is crucial to transparently communicate what we've got planned.
Summary
Currently, the two most common ways of writing GraphQL, which we'd like to target are:
client-preset
While we expect people to migrate from different patterns, these two are the most important to us. The
client-preset
is the next similar (and next newest) alternative togql.tada
and hence lends itself to an automatic migration. Thegraphql-tag
library is still the most popular way of authoring GraphQL documents and is the most popular (as far as we know).Note
A prior version of this RFC mentioned migrating from
gql.tada
back toclient-preset
. However with #160 being scheduled, we won't need a reverse codemod any longer. Reverting any migration patterns is deprioritised, since #160 turnsgql.tada
into a hybrid-alternative that can also function similarly to theclient-preset
.Proposed Solution
Following are sections (TBD) that define the patterns we'd like to recognise and what to convert them to.
Requirements
TODO/TBD
gql.tada
and put new tooling necessary forclient-preset
in placeclient-preset
should be suggested when running an init command, if it's installedThe text was updated successfully, but these errors were encountered: