init: design system 세팅#18
Merged
Merged
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#️⃣ Related Issue
Closes #11
☀️ New-insight
TailwindCSS 사용 시, vscode에서
@tailwind관련 경고(Unknown at rule @tailwind)가 발생할 수 있습니다.이 오류는 Tailwind 전처리를 알지 못하는 기본 CSS Linter로 인해 발생하는데,
vscode 설정에서
css.lint.unknownAtRules를ignore로 바꾸면 경고가 뜨지 않습니다.설정 방법:
Tailwind v4부터는
tailwind.config.js없이도 동작 가능하며,postcss기반 구성만으로도 tailwind를 사용할 수 있습니다.@layer는 base, components, utilities 3단계로 구분되어 작동합니다.
그 중 @layer utilities는 사용자 정의 클래스들을 Tailwind의 유틸리티 클래스처럼 동작하게 만들어주며, 이를 통해 기존 디자인 시스템의 CSS 변수를 활용한 커스텀 클래스들을 손쉽게 확장할 수 있습니다.
💎 PR Point
reset.css: 브라우저 기본 스타일 제거theme.css: 디자인 시스템의 컬러 / 타이포그래피 변수 및 유틸리티 클래스 정의global.css: Pretendard 폰트, Tailwind import, 글로벌 레이아웃 속성 정의@layer를 활용해 Tailwind의 작동 구조에 맞게 스타일을 설정했습니다postcss.config.js,vite.config.ts를 설정했습니다.테스트코드:
📸 Screenshot
Summary by CodeRabbit
Summary by CodeRabbit
New Features
Style
Chores