Skip to content

[조은서] 리액트 과제 끝!#7

Open
eundeok9 wants to merge 21 commits into
Likelion-Inha-10:조은서from
eundeok9:master
Open

[조은서] 리액트 과제 끝!#7
eundeok9 wants to merge 21 commits into
Likelion-Inha-10:조은서from
eundeok9:master

Conversation

@eundeok9

@eundeok9 eundeok9 commented May 7, 2022

Copy link
Copy Markdown

1번
1번

2번
2번_1
2번_2

3번
3번_1
3번_2

@devHudi devHudi left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

안녕하세요 은서님! 리액트를 처음 접해보아 어색하셨을 텐데, 과제 잘 수행해주셨네요!
특히 버튼에 그라데이션을 예쁘게 적용해주셔서 인상깊었던 것 같아요.
몇가지 수정하면 좋을 것들을 코멘트로 남겨드릴게요. 참고만 해주세요 😁

Comment thread src/App.js
Comment on lines +21 to +26
<MediaCard
backgroundImage="https://t4.ftcdn.net/jpg/01/09/88/85/240_F_109888581_d2vqgQnNiNkGRfZPFpIYlS5FIYNBD3ch.jpg"
title="Heading"
text="This is a short description about the card."
backgroundColor="linear-gradient(135deg, #667eea 0%, #764ba2 100%);"
></MediaCard>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이 코드는 아래와 같이 self-closing 을 활용하여 변경할 수 있을 것 같아요. 한번 찾아볼까요?

Suggested change
<MediaCard
backgroundImage="https://t4.ftcdn.net/jpg/01/09/88/85/240_F_109888581_d2vqgQnNiNkGRfZPFpIYlS5FIYNBD3ch.jpg"
title="Heading"
text="This is a short description about the card."
backgroundColor="linear-gradient(135deg, #667eea 0%, #764ba2 100%);"
></MediaCard>
<MediaCard
backgroundImage="https://t4.ftcdn.net/jpg/01/09/88/85/240_F_109888581_d2vqgQnNiNkGRfZPFpIYlS5FIYNBD3ch.jpg"
title="Heading"
text="This is a short description about the card."
backgroundColor="linear-gradient(135deg, #667eea 0%, #764ba2 100%);"
/>

Comment on lines +11 to +24
font-size: 45px;
color: ${(props) => (props.fColor ? props.fColor : "black")};
`;

const ColorWrapper = styled.div`
height: 350px;
border: 1px solid black;
border-top: 0;
border-left: 0;
border-right: 0;
border-top-left-radius: 10px;
border-top-right-radius: 10px;
background-color: ${(props) => (props.bColor ? props.bColor : "black")};
`;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

지금은 혼자 개발하지만, 다른 개발자와 협업을 하게 될 경우 축약하여 네이밍 하는 경우 그 의미를 정확히 전달하기 어려워지는데요, fColorfontColor 로, bColorbackgroundColor 로 명확히 작성하면 더 훌륭한 코드가 될 것 같아요 👍👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants