Skip to content

Commit

Permalink
Merge pull request #4371 from h3poteto/fix/cors
Browse files Browse the repository at this point in the history
Change webSecurity for BrowserWindow to prevent CORS
  • Loading branch information
h3poteto authored May 13, 2023
2 parents 7e8d488 + 8b8b1ed commit b115c7a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/main/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,8 @@ async function createWindow() {
webPreferences: {
nodeIntegration: false,
contextIsolation: false,
// To prevent CORS in renderer process.
webSecurity: false,
preload: path.resolve(__dirname, './preload.js'),
spellcheck: spellcheck
}
Expand Down

0 comments on commit b115c7a

Please sign in to comment.