-
Notifications
You must be signed in to change notification settings - Fork 1.4k
add task solution #1487
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: master
Are you sure you want to change the base?
add task solution #1487
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.
Review Summary
Great job! 🎉 The code is well-structured and meets all the requirements, including the correct use of the key
prop. The components render data correctly. Keep up the good work! 👍
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Footnotes
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.
Good job 👍
Let's improve your code
{' by '} | ||
|
||
<a className="CommentInfo__email" href={`mailto:${comment.email}`}> | ||
{comment.email} |
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.
Use destructuring for comment
const foundUser = usersFromServer.find(user => user.id === post.userId); | ||
const postComments = commentsFromServer.filter( | ||
comment => comment.postId === post.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.
Move this logic to App
component for fix failed tests
return ( | ||
<div className="PostInfo"> | ||
<div className="PostInfo__header"> | ||
<h3 className="PostInfo__title">{post.title}</h3> |
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.
Use destructuring for post
|
||
export const UserInfo = ({ user }) => ( | ||
<a className="UserInfo" href={`mailto:${user.email}`}> | ||
{user.name} |
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.
Use destructuring for user
@@ -1 +1,4 @@ | |||
// add styles here |
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.
Remove comments
// add styles here |
DEMO LINK