diff --git a/frontend/next.config.mjs b/frontend/next.config.mjs index 4678774..48337c7 100644 --- a/frontend/next.config.mjs +++ b/frontend/next.config.mjs @@ -1,4 +1,32 @@ /** @type {import('next').NextConfig} */ -const nextConfig = {}; - -export default nextConfig; +const nextConfig = { + async headers() { + return [ + { + // Apply these headers to all routes in your application + source: '/(.*)', + headers: [ + { + key: 'Access-Control-Allow-Credentials', + value: 'true', + }, + { + key: 'Access-Control-Allow-Origin', + value: '*', // Replace with your allowed origin + }, + { + key: 'Access-Control-Allow-Methods', + value: 'GET,OPTIONS,PATCH,DELETE,POST,PUT', + }, + { + 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, Authorization', + }, + ], + }, + ]; + }, + }; + + export default nextConfig; + \ No newline at end of file diff --git a/frontend/src/pages/index.tsx b/frontend/src/pages/index.tsx index f2ae1d7..af580c8 100644 --- a/frontend/src/pages/index.tsx +++ b/frontend/src/pages/index.tsx @@ -1,10 +1,11 @@ - +import React from 'react'; const Home: React.FC = () => { + return ( -