This is the Hapi integration of Apollo Server. Apollo Server is a community-maintained open-source Apollo Server that works with all Node.js HTTP server frameworks: Express, Connect, Hapi, Koa and Restify. Read the docs.
npm install apollo-server-hapi
With the Hapi plugins
graphiqlHapi you can pass a route object that includes options to be applied to the route. The example below enables CORS on the
The code below requires Hapi 17 or higher.
import Hapi from 'hapi';
Apollo Server is built with the following principles in mind:
- By the community, for the community: Apollo Server’s development is driven by the needs of developers
- Simplicity: by keeping things simple, Apollo Server is easier to use, easier to contribute to, and more secure
- Performance: Apollo Server is well-tested and production-ready - no modifications needed