Skip to content

Instantly share code, notes, and snippets.

@biancadragomir
Last active October 8, 2021 17:29
Show Gist options
  • Save biancadragomir/a4c93ac4011be9e2636cf480db9c11a9 to your computer and use it in GitHub Desktop.
Save biancadragomir/a4c93ac4011be9e2636cf480db9c11a9 to your computer and use it in GitHub Desktop.
Content
import React from 'react';
import * as routes from '../routes';
import { Route, Switch } from 'react-router-dom';
export const Content = () => {
return (
<Switch>
<Route exact path={routes.home} component={HomePage}/
<Route exact path={routes.spaceships} component={SpaceshipsPage} />
<Route exact path={routes.planets} component={PlanetsPage} /
<Route path={routes.stars} component={StarsPage} />
</Switch>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment