The first thing we need to do is to create a directory for our project and initialize a new package.json file installing express, graphql, and express-graphql:
mkdir contacts-graphql cd contacts-graphql npm init --yes npm install express graphql express-graphql babel-preset-env npm install -g babel-cli
We need to install babel-preset-env and babel-cli to use ES6 syntax in Node. Also, we need to create a .babelrc file :
{ "presets": ["env"] }