Skip to content

Commit 45076e0

Browse files
committed
Update next.config.js
1 parent 0cabb62 commit 45076e0

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Diff for: next.config.js

+17
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,23 @@ const nextConfig = {
66

77
reactStrictMode: true,
88

9+
async headers() {
10+
return [
11+
{
12+
// Add a wide open CORS policy for the home page only.
13+
// This allows browser based traffic management to measure performance of the home page.
14+
// May need to rework this if other parts of the site need CORS support.
15+
source: "/",
16+
headers: [
17+
{ key: "Access-Control-Allow-Credentials", value: "true" },
18+
{ key: "Access-Control-Allow-Origin", value: "*" },
19+
{ key: "Access-Control-Allow-Methods", value: "GET,POST" },
20+
{ key: "Access-Control-Allow-Headers", value: "X-CSRF-Token, X-Requested-With, Accept, Accept-Version, Content-Length, Content-MD5, Content-Type, Date, X-Api-Version" },
21+
]
22+
},
23+
]
24+
},
25+
926
async redirects() {
1027
return [
1128
{

0 commit comments

Comments
 (0)