DEV Community

Tom
Tom

Posted on

1

How to combine Next.js, styled components and TypeScript

Next.js provides a handy example of how to add Styled components to your project: https://github.com/vercel/next.js/tree/master/examples/with-styled-components.

However, it's in JavaScript, not in TypeScript. The crux is in _document.tsx of which I've made a typed example in this Github gist.

Top comments (0)

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay