Skip to content

Conversation

@kather0220
Copy link

@kather0220 kather0220 commented Apr 30, 2021

한 달에 걸친 미션 기간이 벌써 끝났네요! 생각보다 빨리 끝날 줄 알았는데 계속 수정하고 싶은게 생겨서 미션하는 데에 시간을 꽤 많이 쓴거 같습니다. 이번 미션을 하면서 혼자 고민도 많이 해보고 폭풍 구글링도 해보고, 디자인에도 신경을 많이 썼습니다. 저번 미션때는 리액트에 대한 이해가 거의 되지 않은 상태였지만 이번 미션을 끝내고서는 그래도 기본적인 것들은 이해하지 않았나 싶은데 잘 모르겠네요...ㅎㅎ 아쉬운 점은 디자인을 고민하느라 추가 기능을 많이 구현하지 못했다는 점입니다. 토요일 오전까지 혹시 시간이 더 있으면 좀 더 도전해보겠습니다. 인스타그램 DM 디자인을 모방하려고 했는데, 인스타그램 디자인이 거의 무채색이더라고요. 그래도 디자인 키워드는 '그라데이션' 이라고 생각해서 여러 군데 포인트를 주고 느낌을 내보려고 했습니다. 다음주도 열심히 하겠습니다~

배포 링크 : https://react-messenger-13th-done-git-main-kather0220.vercel.app/#/

  • 마지막 메시지를 화면에 표시하는 기능을 구현하려고 했는데, 애초에 짜놓은 코드를 너무 많이 수정해야 되는 것 같아서 거의 흉내만 내는 식으로 하게 됐습니다. 방식은 어떻게 하는지 알겠는데 제 코드가 그거에 맞춰서 되어있지 않다 보니 그냥 노가다 처럼 됐네요. 괜히 ChattinData.json 파일 길이만 늘어난게 아닌가 싶지만 한번 시도해봤어요.

Copy link

@sbl133 sbl133 left a comment

Choose a reason for hiding this comment

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

전체적으로 코드가 간결하고 가독성도 좋아서 이해가 쉽고 그만큼 코드리뷰하기도 좋았던거 같아요
동시에 제 난잡한 코드를 반성하게 되네요ㅠㅜ
전체적으로 너무 잘하셔서 도와드리진 못하고 배우고 가네요..
아무튼 이번 주차 미션하시느라 고생하셨습니다!!

return (
<HashRouter>
<Navigation />
<Route path="/" exact={true} component={Home} />
Copy link

Choose a reason for hiding this comment

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

exact 쓸때는 보통 <Route exact path="/" component={Home} />이런식으로 많이 쓰이고 더 편하기도 한거 같아요
혹시 뭔가 다른점이 있다면 알려주세요~

<img src={id.img} alt="friendImg"></img>
<h3>{id.name}<pre> <FiSend></FiSend></pre></h3>
{ChattingData.map(message => {
return(message.receiver===id.id && message.last ?<h5>{message.text}</h5>:<></>)
Copy link

Choose a reason for hiding this comment

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

저는 styled-components로 떡칠을 해놨는데 h3 h5를 구현하신거처럼 styled-components를 사용하면
코드량도 줄고 가독성도 더 좋아지는거 같아요 저도 다음부턴 styled-components 쓸때 생각하고 쓰려고 노력해야겠어요..



const ChattingScreen = () => {
const { id } = useParams();
Copy link

Choose a reason for hiding this comment

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

저는 match라는걸 props로 받아서 params를 사용했는데 이런 방법도 있었내요
좋은 정보 감사합니다

<div onClick={handleClick}>
<ChattingHeader user={users[currentUser]} />
</div>
<Navigation/>
Copy link

Choose a reason for hiding this comment

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

Navigation이 Link들을 설정해 놓은 component인거 같은데 혹시 여기 있을 이유가 있을까요?


function Navigation() {
return(
<StyledNavigationBar>
Copy link

Choose a reason for hiding this comment

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

Link들을 설정할때 아이콘도 넣어야되고 css도 설정해야되서 좀 난잡했는데
따로 빼서 component로 만드니깐 훨씬 가독성이 좋아지는거 같아요
이렇게 또 배워갑니다~

@kather0220 kather0220 changed the title [4주차] 이소정 미션 제출합니다. [3주차] 이소정 미션 제출합니다. May 10, 2021
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