-
Notifications
You must be signed in to change notification settings - Fork 12
[클린코드 7기 이상혁] 점심 뭐 먹지 미션 STEP 3 #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: sanghyuk-2i
Are you sure you want to change the base?
Conversation
- Tab 컴포넌트 생성 - 음식점 상세 정보에 즐겨찾기 여부 표시 추가
- Tabs 이벤트 추가 및 activeTab 상태 추가 - Tab 상태값에 따른 식당 목록 필터화 처리
- 요구사항 확인 및 체크
- 자주 가는 음식점 기능 동작 테스트를 위한 E2E 테스트 코드 추가
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
안녕하세요 상혁님 ~ 3단계는 diff가 많지 않아 코멘트 달 게 별로 없어보이네요! 다만 상태의 성격을 어떻게 구분해야할지 아직 감이 잘오질 않으시는 듯 하여 이 부분에 대해 논의 이어가보면 좋을 것 같습니다 :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
컴포넌트에 스타일을 모두 inline으로 작성하신 이유가 궁금하네요 !
checked | ||
? Icon({ | ||
name: 'favorite-icon-filled', | ||
size: 'md', | ||
removeBackground: true, | ||
}) | ||
: '' | ||
} | ||
${ | ||
!checked | ||
? Icon({ | ||
name: 'favorite-icon-lined', | ||
size: 'md', | ||
removeBackground: true, | ||
}) | ||
: '' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
삼항 연산자 하나로 처리할 수 있지 않을까요?
const json = JSON.stringify(props); | ||
|
||
const isChecked = favorites.some((favoriteId) => favoriteId === id); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isChecked
도 restaurantStore
에서 제공할 수 있지 않을까요? 이걸 다른 곳에서도 쓰는 듯 보여서요.
안녕하세요!!
영화 리뷰 미션과 병행하면서 진행하니까 좀 늦어지고 있는데..
리뷰 잘 부탁드리겠습니다! 🙏
해결하려는 문제 & 해결 방법
기능 요구사항들을 모두 수행해야 한다.
고민한 부분
Tabs을 공통 컴포넌트로 만들어서 재사용성을 높이려고 노력했습니다.
리뷰 요청 사항 & 질문
이렇게 식당 관련 Store에 탭 관련 상태값을 넣었는데, 나중에는 탭 전용 Store를 만들어서 따로 관리하는게 맞을까요?
구현 예시
배포 사이트