Hi I follow your tutorial but when I try to display error.message I get "An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error."
You are running the application in product environment after build. If you start this application with `npm run dev`, you will see 'Error loading review'.
@Codeevolution Thanks for providing this course. I'm following all chapters of this course and I'm facing an error while doing "npm run build". Error - src/app/files/page.tsx Type error: File '/src/app/files/page.tsx' is not a module. How can I fix this error, I'm on episode 24 and I saw that you are not facing this issue when executing same command
I am getting an error while running the "npm run build" command: Linting and checking validity of types ...Failed to compile. .next/types/app/docs/[[...slug]]/page.ts:34:29 Type error: Type '{ params: { slug: string[]; }; }' does not satisfy the constraint 'PageProps'. Types of property 'params' are incompatible. Type '{ slug: string[]; }' is missing the following properties from type 'Promise': then, catch, finally, [Symbol.toStringTag] 32 | 33 | // Check the prop type of the entry function > 34 | checkFields() | ^ 35 | 36 | // Check the arguments and return type of the generateMetadata function 37 | if ('generateMetadata' in entry) { This is my src/app/docs/[[...slug]]/page.tsx: export default async function Docs({ params, }: { params: { slug: string[]; }; }) { const { slug } = await params; if(slug?.length===2) { return Viewing docs for feature {slug[0]} and concept {slug[1]} } else if (slug?.length===1) { return Viewing docs for feature {slug[0]} } return Docs home page!; }
These series of video are awesome, thank you for sharing, please don't stop
Very helpful watching the full series man keep doing what you are doing
Please upload videos regularly. These videos are awesome. Thanks
Dude, your explanation is top notch.
Please add the last two uploaded videos of Next Js 14 in the playlist. These videos are not present in the playlist
Thanks you so much this help me a lot
Hi I follow your tutorial but when I try to display error.message I get "An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error."
same here
The bullet was gracefully dodged indeed.
You are running the application in product environment after build. If you start this application with `npm run dev`, you will see 'Error loading review'.
That's how next.js tries to protect you from silly programming habits, such as logging internal variant values in the error message.
@Codeevolution Thanks for providing this course. I'm following all chapters of this course and I'm facing an error while doing "npm run build". Error - src/app/files/page.tsx
Type error: File '/src/app/files/page.tsx' is not a module. How can I fix this error, I'm on episode 24 and I saw that you are not facing this issue when executing same command
make sure all page.tsx is clean especially src/app/files/page.tsx (this one)
man really alot of thanks to you for the great full content ❤❤
i didnt have the error while starting the app. didnt need the "use client"; in error.tsx
Can I use this in a component?
Hi Vishwas, what if I throw error in layout.tsx file in the same folder, will the errorBoundary able to capture it?? Mine is not.
If this error occurs at the root of the application? For example, when I create a actions.ts (with server actions), and this actions thrown an error
hi, why does everything work correctly in dev mode, but after build and start, returns the default page?
❤❤💕💕 Have a good day.
What them is your vscode
How many videos will be there in this tutorials?
80 plus re
I'm not getting an error in the product build
Fixed it by mentioning 'use client' in page.tsx file
I am getting an error while running the "npm run build" command: Linting and checking validity of types ...Failed to compile.
.next/types/app/docs/[[...slug]]/page.ts:34:29
Type error: Type '{ params: { slug: string[]; }; }' does not satisfy the constraint 'PageProps'.
Types of property 'params' are incompatible.
Type '{ slug: string[]; }' is missing the following properties from type 'Promise': then, catch, finally, [Symbol.toStringTag]
32 |
33 | // Check the prop type of the entry function
> 34 | checkFields()
| ^
35 |
36 | // Check the arguments and return type of the generateMetadata function
37 | if ('generateMetadata' in entry) {
This is my src/app/docs/[[...slug]]/page.tsx:
export default async function Docs({
params,
}: {
params: {
slug: string[];
};
}) {
const { slug } = await params;
if(slug?.length===2) {
return Viewing docs for feature {slug[0]} and concept {slug[1]}
} else if (slug?.length===1) {
return Viewing docs for feature {slug[0]}
}
return Docs home page!;
}
have you figured it?
@@721lakhvirsingh2 not yet
Good day greetings
Not working with yarn start
how do you handle the global-error.tsx file , thanks
My guess is to create a new file named error.tsx in app directory
GoodJob!
Please can someone help me. Why error page doesnt display?
I have only error showed in VS Code terminal: "Error: Error loading review"
code:
import { notFound } from "next/navigation"
function getRandomInt(count: number) {
return Math.floor(Math.random() * count)
}
export default function Review({ params }: {
params: {
productId: string,
reviewId: string,
}
}) {
const random = getRandomInt(2)
if (random === 1) {
throw new Error("Error loading review")
}
if (parseInt(params.reviewId) > 1000) notFound()
return
Review № {params.reviewId} for product № {params.productId}
}
i have the same problem, someone said add " use client"; but it didnt work for me
@@serineber387 add "use client" in page.tsx also