(Full description and list of commands at - https://npmjs.org/doc/index.html)
##List of less common (however useful) NPM commands
######Prepand ./bin to your $PATH Make sure to export your local $PATH and prepand relative ./node_modules/.bin/:
(Full description and list of commands at - https://npmjs.org/doc/index.html)
##List of less common (however useful) NPM commands
######Prepand ./bin to your $PATH Make sure to export your local $PATH and prepand relative ./node_modules/.bin/:
| /* eslint-disable no-console, import/first */ | |
| import path from 'path'; | |
| import express from 'express'; | |
| import expressStaticGzip from 'express-static-gzip'; | |
| import graphqlHTTP from 'express-graphql'; | |
| import PrettyError from 'pretty-error'; | |
| import bodyParser from 'body-parser'; | |
| import raven from 'raven'; | |
| import morgan from 'morgan'; | |
| import { graphqlBatchHTTPWrapper } from 'react-relay-network-layer'; |
| // the main app file | |
| import express from "express"; | |
| import loadDb from "./loadDb"; // dummy middleware to load db (sets request.db) | |
| import authenticate from "./authentication"; // middleware for doing authentication | |
| import permit from "./authorization"; // middleware for checking if user's role is permitted to make request | |
| const app = express(), | |
| api = express.Router(); | |
| // first middleware will setup db connection |
| # Insomnia Configuration | |
| ## Run the test query | |
| { | |
| shop { | |
| id | |
| name | |
| } | |
| } | |
| # Query Structure Examples |