Skip to content

Instantly share code, notes, and snippets.

@ovpv
Created August 6, 2019 17:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ovpv/3dc0b5946960920affaf25c595f12cd9 to your computer and use it in GitHub Desktop.
Save ovpv/3dc0b5946960920affaf25c595f12cd9 to your computer and use it in GitHub Desktop.
Defining routes file for react ssr
import Home from "./client/pages/home/home";
import About from "./client/pages/about/about";
import NotFound from "./client/pages/not-found/not-found";
const Routes = [
{
url: "/",
exact: true,
component: Home
},
{
url: "/about",
exact: false,
component: About
},
{
url: "*",
exact: true,
component: NotFound
}
];
export const MenuLinks = [
{
url: "/",
menuText: "Home"
},
{
url: "/about",
menuText: "About"
}
];
export default Routes;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment