Currently, I have set up my Nuxt.js in default mode with universal and history router configurations.
After running nuxt generate
, the generated website includes an index.html
file in the dist folder.
This means that when the website is published, it can be accessed simply via https://example.com/
.
However, a question arises when trying to navigate to https://example.com/index.html
. Nuxt.js immediately redirects the website to the following message:
This page could not be found
Back to the home page
If browser JavaScript is disabled, then access to the website is possible.
Attempts to resolve this issue using the Validate Method were unsuccessful as it seems to be designed for dynamic routes rather than basic routes like mine.
So, the question remains: How can I configure Nuxt.js to accept both https://example.com/
and https://example.com/index.html
?