Next 13 App Router Realtime - Am I missing something?

I want to have some kind of real time behavior for my app. I've decided that SWR (https://swr.vercel.app/) is the right way to go for me, just for simplicity sake. Imagine I use the Next 13 App Router, make database called in my server components, then render the client components with that data. In this case if I wanted to implements SWR then for that data then I would still have to define a tRPC route to fetch that same data in order to wrap it in the SWR component. So basically that client component would receive the data from its parent server component but then would have to also call the tRPC + SWR for the same data. The same would be true for any real time layer you would implement in the client component. So basically I'm doubling up my data access for this same component. Maybe I'm just asking too much from Server Components, but I was hoping that they would simplify the api and make a lot of the GETs unnecessary. I guess not if you want to have real time. Am I missing something here?
0 Replies
No replies yetBe the first to reply to this messageJoin