Skip to content

Add a basename property to the router #449

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Sija opened this issue May 30, 2021 · 2 comments
Open

Add a basename property to the router #449

Sija opened this issue May 30, 2021 · 2 comments

Comments

@Sija
Copy link
Member

Sija commented May 30, 2021

Similarly to what's react router is offering: https://reactrouter.com/web/api/BrowserRouter/basename-string

@gdotdesign
Copy link
Member

We should investigate using the <base> HTML element for this https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base

@hamidb80
Copy link
Contributor

hamidb80 commented Mar 26, 2025

It's really helpful specially in places like Github page where the pattern of URL is as follows: username.github.io/repo/

I've tried to do it manually i.e. replacing URLs by grep command but it did not so well ...

Also just using <base> tag with the base URL does not seems to work

https://github.com/hamidb80/foss-spa-brain-games

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants