mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
See: https://github.com/vercel/next.js/security/advisories/GHSA-mq59-m269-xvcx and [16.1.7](https://github.com/vercel/next.js/releases/tag/v16.1.7) --------- Co-authored-by: Sebastian "Sebbie" Silbermann <[email protected]>
28 lines
545 B
JavaScript
28 lines
545 B
JavaScript
const allowOpaqueOrigin = process.env.NEXT_TEST_ALLOW_OPAQUE_ORIGIN === '1'
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
module.exports = {
|
|
productionBrowserSourceMaps: true,
|
|
logging: {
|
|
fetches: {},
|
|
},
|
|
headers() {
|
|
return [
|
|
{
|
|
source: '/sandboxed',
|
|
headers: [
|
|
{
|
|
key: 'Content-Security-Policy',
|
|
value: 'sandbox allow-forms',
|
|
},
|
|
],
|
|
},
|
|
]
|
|
},
|
|
experimental: {
|
|
serverActions: {
|
|
allowedOrigins: allowOpaqueOrigin ? ['null'] : [],
|
|
},
|
|
},
|
|
}
|