2min chapter

Frontend First cover image

Playing with Server Components in Vercel’s Edge Runtime

Frontend First

CHAPTER

Using Javascrip to Render a Theme

The use case here was, you want a theme based off a theme. So let's think about if you had that for some other reason. A, you before the react ap renders, you, ah, figure out what the theme is by reading from local storage. And then you set a class on the body element and and the body element. Then a tak basically controls all the c s s a get surrendered so now your c s s is like just going to work because youre your body,. Your body tag at's like theme rid or the and you can do this for a whole bunch of things, like if the users logged in or not. You don't have to deal

00:00

Get the Snipd
podcast app

Unlock the knowledge in podcasts with the podcast player of the future.
App store bannerPlay store banner

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode

Save any
moment

Hear something you like? Tap your headphones to save it with AI-generated key takeaways

Share
& Export

Send highlights to Twitter, WhatsApp or export them to Notion, Readwise & more

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode