A project template for progressive development of Neo4j GraphQL schemas.
A project template for using Apollo GraphQL with a Neo4j graph database.
The below technologies are necessary or recommended to get started with development:
Here is an evolving list of resources for learning more about the above technologies:
neo4j-graphql-js A GraphQL to Cypher query execution layer for Neo4j and JavaScript GraphQL implementations.
@neo4j/graphql Neo4j product beta of neo4j-graphql-js
Run npm install
in your terminal to install project dependencies. The following libraries are used to assist the development of Neo4j-GraphQL schemas:
graphql-tag A JavaScript template literal tag that parses GraphQL queries.
cypher-tag A JavaScript template literal tag for Cypher in GraphQL.
@graphql-workspaces/cli A CLI for GraphQL workflow.
@graphql-workspaces/load A wrapper around the load-files and merge modules from graphql-tools used to load and merge schema files.
Modify the contents of the /schema directory.
Use the print command from @graphql-workspaces/cli to print the merged contents of the /schema
directory to a schema.printed.graphql file next to it. Use the --watch or --validate arguments to watch for file changes or validate the merged type definitions.
gql print schema
gql print schema --watch
gql print schema --validate
Use the below scripts to run the server file and start the API at localhost:4001/graphql or to print the result of the Neo4j-GraphQL augmentation of the merged type definitions in schema.printed.graphql
.
Add, modify, or rename any files or directories in /schema
and repeat workflow.
You can print the result of the schema augmentation process from either neo4j-graphql library using the following scripts which use the gql
cli locally:
npm run print:neo4j-graphql-js
npm run print:neo4j-graphql
All other dependencies are used for building and running the server startup files with the following scripts:
npm run start:neo4j-graphql-js
npm run start:neo4j-graphql