Created
September 9, 2017 05:08
-
-
Save avinashsivaraman/9ee96faff06d9fae4e7d490e98b7d17a to your computer and use it in GitHub Desktop.
To Enable CORS in express server
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
const express = require('express'); | |
const cors = require('cors'); | |
const app = express(); | |
app.use(cors()) | |
app.listen(8080) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment