Created
April 2, 2018 15:09
-
-
Save cramhead/7db17e87f7e4349f2d29383db37663fc to your computer and use it in GitHub Desktop.
Index.js file without cors
This file contains hidden or 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
import express from 'express' | |
const PORT = process.env.PORT || 3000 | |
const app = express(); | |
app.use('/', (req, res) => { | |
res.send(`Server says ${(new Date).toString()}`) | |
}) | |
app.listen(PORT, () => { | |
console.log(`Server running at http://127.0.0.1:${PORT}/`) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment