#How to get omitted error from sourcemaps enabled in production?

8 messages · Page 1 of 1 (latest)

hot sand
#

hi, i face this error in production but not at all in local env. in the global-error page i printed the error

"use client";

export default function GlobalError({
  error,
}: {
  error: Error & { digest?: string };
  reset: () => void;
}) {
  console.log(error);

So should i print error.digest to get the actual err message which has been omitted?

austere brambleBOT
#

🔎 This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord

🕵️ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in id:customize

✅ You can mark a message as the answer for your post with Right click -> Apps -> Mark Solution
(if you don't see the option, try refreshing Discord with Ctrl + R)

frank bronze
#

global-error.js is only enabled in production. In development, our error overlay will show instead.

#

you would get an error overlay instead

hot sand
frank bronze
hot sand
#

oh oops you're right

#

i forgot that