I can't serve the app from a sub-directory
I want the base path of my app be
/admin/
. So for example the users list page would be /admin/users
. I followed your instructions : Serving the application from a subdirectory
(https://refine.dev/docs/api-reference/core/providers/router-provider/#serving-the-application-from-a-subdirectory)
I have a CustomRouterComponent
component:
And I give it to<Refine>
:
Now when I open /admin
it automatically redirects to /admin/users
which is a good sign but nothing renders on that page and any other page in my app. Am I missing something? I don't get any wired error in the console. I don't get a 404. Just nothing renders. All pages are empty.
I'm using Vite+React+TS+React location. All of my dependencies all up-to-date. I've also tried to set base
to /admin/
in vite.config.ts
but it didn't help:
from5 Replies
rival-black•3y ago
Hey @amirhhashemi,
I'm on this. I'm trying to reproduce the issue on my local machine. I'll let you know as soon as possible.
frail-apricotOP•3y ago
Thanks. let me know if you need more information
rival-black•3y ago
I reproduced the issue. You are right. It is a bug, it should work like the reference docs say. Could you open an issue? We will fix it as soon as possible. 🙏🏻
Thanks for reporting.
frail-apricotOP•3y ago
Sure. I'm gonna create an issue right now. Thanks for the confirmation
frail-apricotOP•3y ago
GitHub
[BUG] Can't serve the app from a subdirectory · Issue #3207 · refin...
Describe the bug I exactly followed your instructions on Serving the application from a subdirectory but it didn't work. Another person who I believe is a core team member confirmed that it...