RW 0.28 <Set>
This commit is contained in:
@@ -7,15 +7,18 @@
|
||||
// 'src/pages/HomePage/HomePage.js' -> HomePage
|
||||
// 'src/pages/Admin/BooksPage/BooksPage.js' -> AdminBooksPage
|
||||
|
||||
import { Router, Route, Private } from '@redwoodjs/router'
|
||||
import { Router, Route, Private, Set } from '@redwoodjs/router'
|
||||
import BlogLayout from 'src/layouts/BlogLayout'
|
||||
|
||||
const Routes = () => {
|
||||
return (
|
||||
<Router>
|
||||
<Route path="/contact" page={ContactPage} name="contact" />
|
||||
<Route path="/blog-post/{id:Int}" page={BlogPostPage} name="blogPost" />
|
||||
<Route path="/about" page={AboutPage} name="about" />
|
||||
<Route path="/" page={HomePage} name="home" />
|
||||
<Set wrap={BlogLayout}>
|
||||
<Route path="/contact" page={ContactPage} name="contact" />
|
||||
<Route path="/blog-post/{id:Int}" page={BlogPostPage} name="blogPost" />
|
||||
<Route path="/about" page={AboutPage} name="about" />
|
||||
<Route path="/" page={HomePage} name="home" />
|
||||
</Set>
|
||||
<Private unauthenticated="home">
|
||||
<Route path="/admin/posts/new" page={NewPostPage} name="newPost" />
|
||||
<Route path="/admin/posts/{id:Int}/edit" page={EditPostPage} name="editPost" />
|
||||
|
||||
Reference in New Issue
Block a user