human
human
TTCTheo's Typesafe Cult
Created by human on 5/4/2023 in #questions
Next.js 13 get current URL path in Server Component
For me it doesn't, because they are non-interactive in terms of JS. They don't enhance the experience as they are just anchors. For buttons, I'd rather use forms to handle data submissions. Makes logic a lot simpler and avoids a ton of footguns that comes with managing state and side effects.
43 replies
TTCTheo's Typesafe Cult
Created by human on 5/4/2023 in #questions
Next.js 13 get current URL path in Server Component
Yeah, not what I was looking for since it's a client component. Thanks anyway. I did figure out using the provider (I had a usePathname in my nav that is an SC, that's why it failed). But really, I just wonder why we have to go through hoops to get such context.
43 replies