Try adding x-inertia to the exposed_headers in cors.php
'exposed_headers' => ['x-inertia']
You might need to publish it with php artisan config:publish cors
Here’s a clearer version of your question:
Issue with Laravel 10, Nova 4, and AWS (Inertia.js Error)
I'm experiencing an issue with Laravel 10 and Nova 4 on AWS that does not occur on my localhost or VPS.
When navigating the webpage on AWS, I get the following error:
"All Inertia requests must receive a valid Inertia response, however, a plain JSON response was received."
X-Inertia: true header is missing from the response headers.X-Inertia: true header is correctly included.Please or to participate in this conversation.