Added cors to the index.js
This commit is contained in:
parent
886d07c1fc
commit
845f9dc88d
@ -6,7 +6,7 @@ const app = express();
|
|||||||
app.disable("x-powered-by");
|
app.disable("x-powered-by");
|
||||||
|
|
||||||
const server = http.createServer(app);
|
const server = http.createServer(app);
|
||||||
const io = new Server(server);
|
const io = new Server(server, {cors: {origin: "*"}});
|
||||||
|
|
||||||
io.on("connection", require("./handler/connection"));
|
io.on("connection", require("./handler/connection"));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user