How to get the pagename
Answered
Havana posted this in #help-forum
HavanaOP
how can I get the page name from the
layout.tsx
that was generated with Metadata inside a dynamic routeAnswered by Anay-208 | Ping in replies
5 Replies
@Havana how can I get the page name from the `layout.tsx` that was generated with Metadata inside a dynamic route
you can convert the layout.tsx to a client component and use
usePathname
Answer
wait check this to get dynamic route parameters
HavanaOP
good thing I mentioned the dynamic route
@Anay-208 | Ping in replies you can convert the layout.tsx to a client component and use `usePathname`
HavanaOP
thank you very much