graphql / graphiql

GraphiQL & the GraphQL LSP Reference Ecosystem for building browser & IDE tools.
MIT License
16.08k stars 1.72k forks source link

Discussion: `renderGraphiQL` and middlewares #1117

Open acao opened 4 years ago

acao commented 4 years ago

What if we had a renderGraphiQL package that:

then a bunch of middlewares for different node servers to mount it statically, or to serve it with a lambda

sibelius commented 4 years ago

check this https://github.com/expo/koa-graphiql/blob/master/src/middleware.js

acao commented 4 years ago

great example! renderGraphIQL would take care of all this underlying stuff of generating the html and javascript and all, no more of that! so the actual koa implementation should be under 20 loc. You’ll see!

iFlameing commented 4 years ago

@acao Can I work in this? I read the codebase of https://github.com/expo/koa-graphiql/blob/master/src/middleware.js and understand it.

acao commented 4 years ago

@iFlameing please do! that would be great to start on. open a draft PR whenever you like!