Opening absolute urls in RedwoodJS - SSR

105 views Asked by At

I have a RedwoodJS App with several routes. It's very basic for now and I start the development server with yarn rw dev.

Now I have created some routes:

/ -> HomePage
/sign-in -> SignInPage
/register -> RegisterPage

I can call the routes internally via navigate which works fine. But I cannot call these routes via localhost:8910/register for example. I get a 404 error.

What do I have to do to make (almost) all routes callable directly with their absolute urls?

1

There are 1 answers

0
Rasmus On

A late response to your question, but all the routes are managed in the Routes.tsx-file. In my example, I have a route to access the BikesPage-component (located in .../pages/Bike/BikesPage hence the naming BikeBikesPage).

RedwoodJS routes file

So to ask your question, to make them callable by their absolute name, the name must be the same as the path. Hope that helped you or anyone coming here afterwards!