Provides a working API to expand from for initial development
git remote add upstream git@github.com:lancegliser/node-express-apollo-graphql.git
Once server is running (npm run-script dev:watch
)
You may load and interact with data through the
playground.
This API works from a GraphQL first approach.
Each component you wish to write starts with a .graphql
file.
The types in it will cause typescript code to be generated
by running the following command:
npm run graphql-codegen
The generated classes are created at:
src/generated/types.ts
You can import those types in your own resolver, providing you strong contracts and stub implementations.
Integration tests are run using Jest to create an instance of the API on a random port using Node. Testing supplies its own user context.
Jest can use a local .env
file for process environment variables.