Replies: 2 comments 7 replies
|
Hi, Are you using a custom server? I cannot reproduce this locally. This error happens when a This is handled internally by Next.js, and my guess is that the second argument (the origin/host) is missing, or is something like "0.0.0.0", or "localhost", without protocol. It could also be that the EditIf using "serve": {
"executor": "@nrwl/next:server",
"options": {
"buildTarget": "website:build",
"dev": true,
"port": 4200,
"hostname": "localhost"
},
...
} |
|
Updates: So how I'm able to fix this problem... |



Updates:
I build new separate project only with Next.Js. I did the same things.. like folder structure and used the same middleware.ts file. And it's working. i.e if I don't have 'cookies' I get redirected to auth/login. Currently the main project it's build with Nx mono repos. Check here: https://nx.dev/packages/next
So how I'm able to fix this problem...