From dfd16cef2f44a34f71f2854e7efb235eeb750620 Mon Sep 17 00:00:00 2001 From: Kalle <38327916+Sendouc@users.noreply.github.com> Date: Sun, 23 Oct 2022 12:49:05 +0300 Subject: [PATCH] Fix errors not getting logged --- .eslintrc.js | 1 + app/root.tsx | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index cb9b9e50c..1d0db8d65 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -30,6 +30,7 @@ module.exports = { "@typescript-eslint/no-unsafe-argument": 0, "@typescript-eslint/no-non-null-assertion": 0, "@typescript-eslint/no-explicit-any": 0, + "react/prop-types": 0, }, settings: { react: { diff --git a/app/root.tsx b/app/root.tsx index b93d03d18..65805ac7b 100644 --- a/app/root.tsx +++ b/app/root.tsx @@ -1,3 +1,4 @@ +import type { ErrorBoundaryComponent } from "@remix-run/node"; import { json, type LinksFunction, @@ -156,7 +157,9 @@ export function CatchBoundary() { ); } -export function ErrorBoundary() { +export const ErrorBoundary: ErrorBoundaryComponent = ({ error }) => { + console.error(error); + return ( @@ -164,4 +167,4 @@ export function ErrorBoundary() { ); -} +};