Skip to content

Instantly share code, notes, and snippets.

@abohannon
Last active February 1, 2018 18:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abohannon/600ca3f3eb11c07bd4f3f6fcbed16cab to your computer and use it in GitHub Desktop.
Save abohannon/600ca3f3eb11c07bd4f3f6fcbed16cab to your computer and use it in GitHub Desktop.
const express = require('express');
const bodyParser = require('body-parser');
const app = express();
const routes = require('./routes');
app.use(bodyParser.json());
app.use(express.static(`${__dirname}/public`));
routes(app);
const PORT = process.env.PORT || 3000
app.listen(PORT, () => {
console.log(`Listening on port ${PORT}!`)
});
module.exports = app;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment