[blog] Component-level CSS-in-JS 번역 #11
Merged
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.
🚀 Todo
📝 Summary
[Ant Design 5.0과 "component level" CSS-in-JS 솔루션]
해시: Ant Design은 현재 버전과 테마 변수에 대해서만 해시 값 계산을 진행하여 적용시킵니다.
컴포넌트 캐싱: Ant Design 컴포넌트의 props는 스타일의 구조에 영향을 미치지 않고, 최초 마운트 시 스타일을 한 번만 생성하고 이후에는 캐시된 스타일을 재사용합니다.
성능 비교: Ant Design은 성능 테스트에서 다른 라이브러리와 비교했을 때, 첫 번째와 두 번째 렌더링에서 성능 우위를 보였습니다. 하지만 props가 스타일 계산에 영향을 미칠 때는 여전히 일부 성능 부담이 존재합니다.
한계: Ant Design의 "component level" CSS-in-JS 솔루션은 성능에 이점을 제공하지만, 일반적인 애플리케이션 구축에는 적합하지 않으며, 주로 컴포넌트 라이브러리에 적합합니다.
🔍 고민했던 부분
컴포넌트 스타일
이 컴포넌트의 기본적인 스타일의 구조를 의미하는 것 같은데 다른 분들은 컴포넌트 스타일이라는 용어에 있어서 안 헷갈리시는지 궁금하고, 잘못 번역한 부분이 있다면 말씀부탁드립니다!