Next.js Discord

Discord Forum

Get ID from a dynamic page

Unanswered
Yacare Caiman posted this in #help-forum
Open in Discord
Yacare CaimanOP
Does anyone know how to get the ID of a dynamic page in Next.js when most of the code is running on the server? I've tried using useRouter but it doesn't seem to work in this context

12 Replies

Yacare CaimanOP
In a component i can’t get it?
You can get it by passing it as props down
@Yacare Caiman solved?
Yacare CaimanOP
Not yet
It is a personal project and I have too much time to make it
@Yacare Caiman Not yet
what information is missing to resolve your issue?
Yacare CaimanOP
At this time, nothing I don’t try yet I said, says before
@Yacare Caiman ?
Yacare CaimanOP
Idk
@Yacare Caiman Idk
:meow_stare: