By Alex Merced Updates by Ira Herman
- Use React Router's
BrowserRouter
,Link
,Route
,Redirect
, andSwitch
Example resource: fruits
In I.N.D.U.C.E.S. route order:
URL | HTTP Verb | Action | Notes |
---|---|---|---|
/fruits/ | GET | index | INDEX when a user types localhost:3000/fruits in browser this route shows a list or index of all fruits |
/fruits/new | GET | new | NEW when a user types localhost:3000/fruits/new in browser this route shows the user a form to create a NEW fruit |
UPDATE IN PROGRESS:
Experimenting with this instead: