()
| 128 | }) |
| 129 | |
| 130 | const PostsIndexComponent = () => { |
| 131 | const navigate = useNavigate() |
| 132 | return ( |
| 133 | <> |
| 134 | <h1>Posts Index</h1> |
| 135 | <button |
| 136 | onClick={() => |
| 137 | navigate({ |
| 138 | from: '/posts/', |
| 139 | to: './$postId', |
| 140 | params: { postId: 'id1' }, |
| 141 | }) |
| 142 | } |
| 143 | > |
| 144 | To the first post |
| 145 | </button> |
| 146 | </> |
| 147 | ) |
| 148 | } |
| 149 | |
| 150 | const postsIndexRoute = createRoute({ |
| 151 | getParentRoute: () => postsRoute, |
nothing calls this directly
no test coverage detected