Skip to content

Commit b09cbf0

Browse files
Updated cors config
1 parent cc46549 commit b09cbf0

File tree

1 file changed

+1
-16
lines changed

1 file changed

+1
-16
lines changed

nuxt.config.js

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -78,22 +78,7 @@ export default {
7878
// @ts-ignore
7979
cors: {
8080
credentials: true,
81-
// allowedHeaders: ['Content-Type', 'Authorization'],
82-
origin: ['https://nuxt-socket-io.netlify.app'],
83-
// methods: ['GET', 'POST']
84-
// origin (origin, callback) {
85-
// const whitelist = [
86-
// // 'http://localhost:3001', // Works for local dev
87-
// 'https://nuxt-socket-io.netlify.app'
88-
// ]
89-
// console.log('origin', origin)
90-
// if (whitelist.includes(origin)) {
91-
// console.log('white list includes origin!', origin)
92-
// callback(null, true)
93-
// } else {
94-
// callback(new Error('Not allowed by CORS'))
95-
// }
96-
// }
81+
origin: ['https://nuxt-socket-io.netlify.app']
9782
}
9883
},
9984
sockets: [

0 commit comments

Comments
 (0)