adonis-apollo
Apollo GraphQL server for AdonisJs.
Installation
npm i adonis-apollo
node ace invoke adonis-apollo
- Add
"app/Schemas/*"
to the "copyToBuild" array in .adonisrc.json
.
Usage
Bind the apollo server to your AdonisJs application.
In start/routes.ts
:
import ApolloServer from '@ioc:ApolloServer';
ApolloServer.applyMiddleware({ Route });
Configuration
TODO
Uploads
To enable support for GraphQL uploads:
- Update the config of the bodyparser in
config/bodyparser.ts
by adding your GraphQL route (by default: /graphql
) to the multipart.processManually
array. - Add the Upload scalar to your schema:
scalar Upload
.
License
MIT