-
(* stackoverflow: https://stackoverflow.com/questions/75442550 *) I have a website made by docusaurus I think a url should be consistent before and after reloading. And like StackOverflow, a good style is not having Then, I deployed this change to my production server with docker and nginx. But loading most of the pages of the website returned a 404 error, while static contents could be loaded. Reloading nginx or recreating docker containers did not help. By contrast, setting So does anyone know why PS: docusaurus.config.js:
nginx configuration:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
You can't just set |
Beta Was this translation helpful? Give feedback.
You can't just set
trailingSlash
to anything and expect things to work—you have to make sure your server is properly set up to handle that route. This config is exactly invented to mirror your server's capabilities. If it works withtrailingSlash: true
but notfalse
, it means you should usetrailingSlash: true
, unless you really want to make the other work ;)