Skip to content

Commit

Permalink
Add unsafe-eval to CSP
Browse files Browse the repository at this point in the history
  • Loading branch information
inescri committed Jul 24, 2024
1 parent f90d9ca commit d8fa52c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion packages/demo/configs/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ const extraDevServerConfig = {
host: '127.0.0.1',
port: 5283,
headers: {
'Content-Security-Policy': "default-src 'unsafe-inline' localhost:5284 'self' blob: data:",
'Content-Security-Policy':
"default-src 'unsafe-inline' 'unsafe-eval' localhost:5284 'self' blob: data:",
},
} as const;

Expand Down
2 changes: 1 addition & 1 deletion packages/tests/configs/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export default defineConfig({forGitHubPages: false}, async (baseConfig) => {
port: 5283,
headers: {
'Content-Security-Policy':
"default-src 'unsafe-inline' localhost:5284 'self' blob: data:",
"default-src 'unsafe-inline' 'unsafe-eval' localhost:5284 'self' blob: data:",
},
} as const;

Expand Down
3 changes: 2 additions & 1 deletion packages/toniq-nft-frame/configs/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ export default defineConfig({forGitHubPages: false}, async (baseConfig) => {
}
: {
headers: {
'Content-Security-Policy': "default-src 'unsafe-inline' 'self' blob: data:",
'Content-Security-Policy':
"default-src 'unsafe-inline' 'unsafe-eval' 'self' blob: data:",
},
}),
} as const;
Expand Down

0 comments on commit d8fa52c

Please sign in to comment.