Graphql2ts Save

Transform .graphql to graphql-js typescript

Project README

graphql2ts

graphql2ts Logo

Transform .graphql files to graphql-js typescript code

History

We first had graphql-js implementation, but developers weren't happy with it. So it was born schema first with graphql-tools, merge-graphql-schemas, graphql-modules.

There is also a codemod to transform your .js files to .graphql files: jscodeshift-graphql-files.

After a lot of time, schema first showed some scaling problems, Schema First Problems, mostly because it does not colocate schema with resolvers, and code is much more powerful to implement abstraction on top of it.

This codemod exists to helps us move back to code first approach (graphql-js and related tools).

It will transform a .graphql file and transform in a graphql-js .ts declartion

How to run

npx graphql2ts myschema.graphql mySchemaOutput.ts

How to test

yarn jest
Open Source Agenda is not affiliated with "Graphql2ts" Project. README Source: sibelius/graphql2ts
Stars
41
Open Issues
21
Last Commit
1 year ago
Repository

Open Source Agenda Badge

Open Source Agenda Rating