ShakaCode | ShakaCode Blog | Rails On Maui Blog | Rails | ReactJs | JavaScript | Webpack | Productivity |

How do I link to and from Rails views from my React app?


#1

First of all, thanks for this awesome gem. This is the first time I’ve felt truly motivated to learn Javascript since starting with Rails.

I’d like to know the React on Rails way of linking to and from Rails views to the React apps/components within my project. Would I be using React Router for this? I’m new to React, so any help would be appreciated.

Thanks again,
Dominic


#2

@domi91c Thank you for the kind words!

I don’t quite understand your question. I think you probably just need to set up the anchor tag to point to the right relative URL.

We do, however, use react-router quite a bit within a sub-url.