GraphQL server using node / express and written in ES6 (ES2015) and ES7 (ES2016)
npm i
create a file in the project root called .env
and within it set environment variables NEO4J_USER
and NEO4J_PASS
. Note you can also edit database credentials in the file src/lib/db.js
example .env
file
NODE_ENV=development
NEO4J_USER=neo4j
NEO4J_PASS=neo4j
DEBUG=api:*
to start, run:
npm start
To run tests:
npm test
Tests will use the database credentials in the file src/lib/db.js
as I've not yet configured Mocha to use the dotenv .env
file.
- GraphQL
- Express
- Neo4j
- node-neo4j (
^2.0.0-RC2
)
- node-neo4j (
- ES6/ES7
- ES6 goodness
- async/await
- rest & spread operators
- Mocha
- Mocha w/ chai, and chai-as-promised
- supertest
- Babel (
^6.3.0
) - ESLint
- Uses Standard Style by default, but you're welcome to change this!
- Includes separate test-specific
.eslintrc
to work with Mocha and Chai
- dotenv
- used for loading environment variables
- Project structure is WIP
- Move GraphQL code into modules/models
- Add custom GraphQL scalar types