[fix] styled-components unknown prop warning 제거#377
Conversation
|
""" Walkthrough이 변경사항은 Changes
Assessment against linked issues
Suggested labels
Suggested reviewers
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (4)
✅ Files skipped from review due to trivial changes (2)
🚧 Files skipped from review as they are similar to previous changes (1)
🔇 Additional comments (1)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
✅ Deploy Preview for moadong ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
일단 먼저 1. DOM 정리
2. 명시적인 의도
복잡한 어플리케이션에서는 성능이 개선된다고 합니다. 아직 저희 서비스는 복잡하지 않아 큰 이점을 가질 수는 없겠지만, 명확성 향상 측면에서 도움이 될 것 같습니다. |

#️⃣연관된 이슈
📝작업 내용
warning 화면
1번
2번
3번
4번
5번
6번
7번
8번
9번
문제 원인
styled-components는 사용자 정의 props를 자동 필터링하지 않기 때문에,isFocused가 실제 DOM (<form>,<button>)에 전달되어 React 콘솔 경고가 발생했습니다.isAnimating,isActive,state,isClicked,imageSrc,varient,bgColor,textColor도 같은 이유입니다.해결
isFocusedprops를$isFocused로 변경하여 styled-components의 transient prop 기능을 적용했습니다.isAnimatingprops를$isAnimating로 변경했습니다.isFocused가 DOM에 전달되어 발생하던 경고 메시지를 제거했습니다.중점적으로 리뷰받고 싶은 부분(선택)
논의하고 싶은 부분(선택)
🫡 참고사항
Summary by CodeRabbit
Summary by CodeRabbit
$접두어가 붙는 형태로 일관되게 변경되어 UI 구성 요소의 내부 코드 품질이 향상되었습니다. 사용자에게 보이는 기능이나 동작에는 변화가 없습니다.