Coder Social home page Coder Social logo

Comments (2)

axel7083 avatar axel7083 commented on July 28, 2024 1

Thanks for the amazing explanation 👍 !

I don't think we really need to fix anything here. At best we could ignore the error, or emit a more user-friendly error message.

Yes this is what I expect, having either a more friendly error, or ignore it.

But it looks good enough to me honestly, because you figured out that you had twice the same redirect already. The question is: why did you add twice the same redirect in the first place? Have you tried with only one redirect, and what motivated you to add a second redirect?

No idea; I arrived later after it was like this, and the person who did that is not here anymore.

from docusaurus.

slorber avatar slorber commented on July 28, 2024

This is most likely because your file system is case-insensitive, unlike your CI

The 2nd redirect file can only be created unless the file system is case sensitive and allow both files to exist.

What would you expect to happen, for both environments, in this case?

I'd recommend against emitting twice the file. Many hosts will support serving static files in a case-insensitive fashion and just emitting lower-case redirect files should be enough.

For example Netlify:

GitHub Pages:

I think some hosts like Vercel are case sensitive. But the truth is, you shouldn't use client directs with any host that support server redirects instead.

Server redirects are always a better option, and to my knowledge only GitHub pages do not support server directs, so the only good reason to use client directs is if you deploy to GitHub Pages (or similarly very limited host), which is case insensitive.

Note docusaurus serve is also case insensitive so if you use it for self-hosting, no need to duplicate your redirects.


For these reasons I'm going to close for now, but still curious to see what you expect from Docusaurus in this case.

I don't think we really need to fix anything here. At best we could ignore the error, or emit a more user-friendly error message.

But it looks good enough to me honestly, because you figured out that you had twice the same redirect already. The question is: why did you add twice the same redirect in the first place? Have you tried with only one redirect, and what motivated you to add a second redirect?

from docusaurus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.