File tree Expand file tree Collapse file tree 3 files changed +13
-1
lines changed Expand file tree Collapse file tree 3 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 1
1
const HomePage = ( ) => {
2
2
return (
3
- < div > Home Page </ div >
3
+ < h1 > 프로젝트로 배우는 리액트 </ h1 >
4
4
) ;
5
5
} ;
6
6
Original file line number Diff line number Diff line change
1
+ const NotFoundPage = ( ) => {
2
+ return (
3
+ < div > 404 Page Not Found</ div >
4
+ )
5
+ }
6
+
7
+ export default NotFoundPage ;
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import EditPage from './pages/EditPage';
4
4
import ListPage from './pages/ListPage' ;
5
5
import AdminPage from './pages/AdminPage' ;
6
6
import ShowPage from './pages/ShowPage' ;
7
+ import NotFoundPage from './pages/NotFoundPage' ;
7
8
8
9
const routes = [
9
10
{
@@ -32,6 +33,10 @@ const routes = [
32
33
{
33
34
path : '/blogs/:id' ,
34
35
component : ShowPage
36
+ } ,
37
+ {
38
+ path : '*' ,
39
+ component : NotFoundPage
35
40
}
36
41
] ;
37
42
You can’t perform that action at this time.
0 commit comments