refactor(css): 인라인 스타일 → Tailwind CSS 리팩토링 (3,500+ → 1,286건) #57
불러오는 중...
Reference in New Issue
Block a user
No description provided.
Delete Branch "feature/css-refactoring"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
style={{}}3,500+건 → 1,286건으로 63% 감소@layer base/components분리,wing-*디자인 시스템cn()유틸리티 함수 추가 (className 조합)App.css삭제 →components.css로 통합변경 내역
Phase 0: CSS 인프라 구축
index.css→ 7줄 엔트리포인트 (@import + @tailwind)common/styles/base.css생성 (@layer base 추출)common/styles/components.css생성 (@layer components 통합)common/styles/wing.css생성 (wing-* 디자인 시스템)tailwind.config.js색상값 CSS 변수에 맞춰 수정Phase 1: body default 일괄 제거 (~1,055건)
fontFamily: var(--fK)781건 삭제 (body에서 상속)color: var(--t1)274건 삭제 (body에서 상속)Phase 2~3: Tailwind 유틸리티 변환 (~1,823건)
text-text-2,bg-bg-1등text-[#hex]arbitrary values남은 1,286건 (의도적 유지)
color: item.color,width: ${pct}%Test plan
npx vite build성공 (JS 2,884KB, CSS 144KB)tsc -b타입 체크 통과🤖 Generated with Claude Code
Phase 0: CSS 인프라 구축 - Tailwind config 색상 불일치 수정 (t1/t2/t3 → CSS 변수 값으로 통일) - index.css 1,302줄 → @import 엔트리포인트 7줄로 축소 - common/styles/base.css: @layer base 추출 (CSS 변수, 리셋, body 기본값) - common/styles/components.css: @layer components + utilities 추출 - common/styles/wing.css: wing-* 디자인 시스템 클래스 신규 정의 - common/utils/cn.ts: className 조합 유틸리티 - App.css 삭제 (내용을 components.css로 통합) Phase 1: body default 인라인 스타일 일괄 제거 - fontFamily: 'var(--fK)' 781건 제거 (body font-family 상속) - color: 'var(--t1)' 274건 제거 (body color 상속) - 빈 style={{}} 78건 정리 - 31개 파일, JS 번들 23KB 감소 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>