I have a NextJS app page that should be SSG. I'll fetch all the data that it needs during build time.
But a small part of the code (social media share link) needs information about the device of the user. Basically, I want to know whether I'm on desktop or mobile.
What is the recommended approach for that scenario?
Should I render one of the two possibilities on build time and add some client useEffect
code to detect and change it if necessary?