Skip to content

Instantly share code, notes, and snippets.

@ryanjyost
Created January 4, 2020 23:12
Show Gist options
  • Select an option

  • Save ryanjyost/df8a8f90e3aa583acb5be82aba45c45d to your computer and use it in GitHub Desktop.

Select an option

Save ryanjyost/df8a8f90e3aa583acb5be82aba45c45d to your computer and use it in GitHub Desktop.
Example 8
const ROUTES = [
{ path: "/", key: "ROOT", exact: true, component: () => <h1>Log in</h1> },
{
path: "/app",
key: "APP",
component: RenderRoutes, // here's the update
routes: [
{
path: "/app",
key: "APP_ROOT",
exact: true,
component: () => <h1>App Index</h1>,
},
{
path: "/app/page",
key: "APP_PAGE",
exact: true,
component: () => <h1>App Page</h1>,
},
],
},
];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment