Created
February 11, 2018 19:53
-
-
Save kutliev/0afb1e5d5ef147be17f7d581f11ee85a to your computer and use it in GitHub Desktop.
Simple NodeJS server
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// server.js | |
const express = require('express'); | |
const app = express(); | |
// Run the app by serving the static files | |
// in the dist directory | |
app.use(express.static(__dirname + '/dist')); | |
// Start the app by listening on the default | |
// Heroku port | |
app.listen(process.env.PORT || 5000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment