({ error }: ErrorComponentProps)
| 107 | }) |
| 108 | |
| 109 | function PostErrorComponent({ error }: ErrorComponentProps) { |
| 110 | if (error instanceof NotFoundError) { |
| 111 | return <div>{error.message}</div> |
| 112 | } |
| 113 | |
| 114 | return <ErrorComponent error={error} /> |
| 115 | } |
| 116 | |
| 117 | function PostComponent() { |
| 118 | const post = postRoute.useLoaderData() |
nothing calls this directly
no outgoing calls
no test coverage detected