diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main/js/src/components/errors/Error404.js | 8 | ||||
-rw-r--r-- | src/main/js/src/global-styles.css (renamed from src/main/js/src/index.css) | 0 | ||||
-rw-r--r-- | src/main/js/src/index.js | 10 |
3 files changed, 11 insertions, 7 deletions
diff --git a/src/main/js/src/components/errors/Error404.js b/src/main/js/src/components/errors/Error404.js new file mode 100644 index 00000000..13ce5ae5 --- /dev/null +++ b/src/main/js/src/components/errors/Error404.js @@ -0,0 +1,8 @@ +import React from 'react' +import { Link } from 'react-router' + +const Error404 = () => <div> + <h1>No Match</h1> + <Link to="/">Take me back home ! 🏠</Link> +</div> +export default Error404
\ No newline at end of file diff --git a/src/main/js/src/index.css b/src/main/js/src/global-styles.css index b4cc7250..b4cc7250 100644 --- a/src/main/js/src/index.css +++ b/src/main/js/src/global-styles.css diff --git a/src/main/js/src/index.js b/src/main/js/src/index.js index cfe654b5..f2be8a53 100644 --- a/src/main/js/src/index.js +++ b/src/main/js/src/index.js @@ -7,19 +7,15 @@ import configureStore from './store' const initialState = {} const store = configureStore(initialState) -import './index.css' +import './global-styles.css' import App from './containers/App' - -const NoMatch = () => { - return <h1>No Match</h1> -} - +import Error404 from './components/errors/Error404' ReactDOM.render( <Provider store={store}> <BrowserRouter> <div className="app"> <Match exactly pattern="/" component={App} /> - <Miss component={NoMatch} /> + <Miss component={Error404} /> </div> </BrowserRouter> </Provider>, |