-
Notifications
You must be signed in to change notification settings - Fork 11
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
6번째 과제 - 최성임 #6
base: main
Are you sure you want to change the base?
6번째 과제 - 최성임 #6
Conversation
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.
- props와 컴포넌트를 적절하게 잘 사용하셨고, 이미지를 다르게 하시느라 번거로우셨을텐데 디테일까지 잘 구현하신 거 같습니다~!
- commit 을 잘 해주셔서 어떤 기능들이 추가됐는지 잘 파악이 되는 것 같습니다
styled-components
라이브러리와 관련한 의문점은 저도 함께 고민해보도록 하겠습니다- 기초 개념만 알고 있었는데 성임님 코드리뷰를 통해 코드 작성하는 방법에 대해서 매번 알아갑니다. 좋은 기회 주셔서 감사해요:) 수고하셨습니다!
function App() { | ||
return ( | ||
<div className='AppBody'> | ||
{/* 상단바 */} |
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.
각 항목별로 주석을 잘 달아주셔서 코드 가독성이 좋은 것 같습니다!
<MiddleIcon> | ||
<Search> | ||
<p>검색</p> | ||
<FaKeyboard size='16px' style={{color: '#858585'}}/> |
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.
이 코드가 돋보기 부분바탕 색깔 변형 부분일까요?!
저도 몰랐는데 성임님 코드 리뷰를 통해 배워갑니다:)
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.
바로 밑에 SearchButton이 돋보기 부분입니다! 부모요소인 MiddleIcon에 overflow: hidden;
를 해주면 자식요소의 튀어나옴 없이 깔끔하게 구현해낼 수 있었습니다!
return( | ||
<FilterbarWrapper> | ||
{/* 필터 버튼 목록 */} | ||
<FilterButton>전체</FilterButton> |
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.
Button을 단순히 Button 그 자체로만 사용할 수 있는 줄로만 알았는데 FilterButton등의 형식으로 변형하여 사용할 수도 있겠군요..!
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.
넵 styled-components
라이브러리를 사용하면 css파일을 만들어서 스타일 효과를 부여하는 것 아니라, 컴포넌트 기반으로 스타일 효과를 지원하기 때문에, 위는 버튼을 FilterbarButton이라는 컴포넌트를 만들어서 스타일을 부여하도록 한것입니다!!
@YoonKeumJae 리뷰완료했습니다~~ |
개발 과정
1. 레이아웃 구성
개발에 앞서 구현할 레이아웃을 먼저 파악하고, 필요한 컴포넌트를 구상함
위와 같이 컴포넌트를 구성하고, 중복되는 요소인 VideoDetail과 ShortsDetail컴포넌트를 제작하여 재사용에 용이하도록 구현함.
2. 폴더 구성
components
폴더에 컴포넌트 관련 js파일을 넣고,디자인 구현에 사용되는 image파일들은
images
폴더에 넣어 관리함App.js에서 컴포넌트의 구성은 아래와 같다
![컴포넌트 구성](https://private-user-images.githubusercontent.com/107929413/328804458-cae153e3-fd6f-4ac8-a278-eb10d03503e4.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNDUyMzQsIm5iZiI6MTczOTI0NDkzNCwicGF0aCI6Ii8xMDc5Mjk0MTMvMzI4ODA0NDU4LWNhZTE1M2UzLWZkNmYtNGFjOC1hMjc4LWViMTBkMDM1MDNlNC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxMVQwMzM1MzRaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT02YWRkMjE0YjMwMzQxMmI5NmM5OGVjMjhhYjI3ODlmZjNkOTE0NTQ1NTQzZmIwOTM0ZDcxMDFkOWJkN2VkZjBmJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.eTGtZBa1SXxy2SEmEE1GCVHf5CVM_HwrJWERQiaGGnE)
3. 개발 과정
styled-components
라이브러리를 사용하여 구현함react-icons
라이브러리를 사용하여 구현함4. 결과 화면
5. 과제 진행 중 어려웠던 점
styled-components
라이브러리를 사용하여 스타일을 구현하니 깔끔하긴 했지만 컴포넌트 기반이기 때문에 뒤로 갈수록 생각나는 이름이 없어서 은근히 고민이 됐음. 그리고 단순 css를 사용하는 것이 좀 더 빠르다고 느꼈음. 두 가지를 적절하게 섞어서 사용해야 하는 것이 좋은지 의문.