대단한 동현 블로그
styled-component -> tailwindcss migration reset css
<frontend> 2024. 8. 1. 22:12

어이 당신. 혹시 nextjs에서 styled-component를 사용하기 위해 죄다 use client를 박고 있지 않은가?용기를 가지고 tailwindcss로 마이그레이션을 진행하다 reset css가 둘이 달라서 레이아웃이 다 뭉개지지 않는가?바로 그게 접니다. tailwind의 base layer에서 초기화 해주지만 reset css와 스타일이 조금씩 다르다때문에 base를 재적용하고 덮어씌웠다/* global.css */@tailwind base;@tailwind components;@tailwind utilities;@layer base { /* Reset styles */ html, body, div, span, applet, object, iframe, h1, h2, h..