Open
Conversation
sbl133
reviewed
May 8, 2021
| return ( | ||
| <HashRouter> | ||
| <Navigation /> | ||
| <Route path="/" exact={true} component={Home} /> |
There was a problem hiding this comment.
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>:<></>) |
There was a problem hiding this comment.
저는 styled-components로 떡칠을 해놨는데 h3 h5를 구현하신거처럼 styled-components를 사용하면
코드량도 줄고 가독성도 더 좋아지는거 같아요 저도 다음부턴 styled-components 쓸때 생각하고 쓰려고 노력해야겠어요..
|
|
||
|
|
||
| const ChattingScreen = () => { | ||
| const { id } = useParams(); |
There was a problem hiding this comment.
저는 match라는걸 props로 받아서 params를 사용했는데 이런 방법도 있었내요
좋은 정보 감사합니다
| <div onClick={handleClick}> | ||
| <ChattingHeader user={users[currentUser]} /> | ||
| </div> | ||
| <Navigation/> |
There was a problem hiding this comment.
Navigation이 Link들을 설정해 놓은 component인거 같은데 혹시 여기 있을 이유가 있을까요?
|
|
||
| function Navigation() { | ||
| return( | ||
| <StyledNavigationBar> |
There was a problem hiding this comment.
Link들을 설정할때 아이콘도 넣어야되고 css도 설정해야되서 좀 난잡했는데
따로 빼서 component로 만드니깐 훨씬 가독성이 좋아지는거 같아요
이렇게 또 배워갑니다~
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
한 달에 걸친 미션 기간이 벌써 끝났네요! 생각보다 빨리 끝날 줄 알았는데 계속 수정하고 싶은게 생겨서 미션하는 데에 시간을 꽤 많이 쓴거 같습니다. 이번 미션을 하면서 혼자 고민도 많이 해보고 폭풍 구글링도 해보고, 디자인에도 신경을 많이 썼습니다. 저번 미션때는 리액트에 대한 이해가 거의 되지 않은 상태였지만 이번 미션을 끝내고서는 그래도 기본적인 것들은 이해하지 않았나 싶은데 잘 모르겠네요...ㅎㅎ 아쉬운 점은 디자인을 고민하느라 추가 기능을 많이 구현하지 못했다는 점입니다. 토요일 오전까지 혹시 시간이 더 있으면 좀 더 도전해보겠습니다. 인스타그램 DM 디자인을 모방하려고 했는데, 인스타그램 디자인이 거의 무채색이더라고요. 그래도 디자인 키워드는 '그라데이션' 이라고 생각해서 여러 군데 포인트를 주고 느낌을 내보려고 했습니다. 다음주도 열심히 하겠습니다~
배포 링크 : https://react-messenger-13th-done-git-main-kather0220.vercel.app/#/