Solution#4305
Conversation
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
This solution requires changes before approval. There are two critical violations of task requirements:
1. Incorrect prop passing in src/App.jsx: The last three Sum instances explicitly pass default values (b={0}, a={0}, a={0} b={0}) when the requirements explicitly state these should have "no b prop", "no a prop", and "no params at all" respectively. By passing these values explicitly, you're defeating the test scenario that verifies the component's default parameter handling. Remove these props entirely to let the component's defaults take over.
2. Missing string interpolation in src/components/Sum/Sum.jsx: Checklist item #2 requires using template literal syntax inside the <p> tag content. Replace the JSX expression concatenation with:
<p>{`Sum of ${a} and ${b} is ${a + b}`}</p>The core Sum component logic and default parameter setup are correct—these are the only remaining issues blocking approval.
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Important
Fix the issues, commit the changes, and then re-request my review using the Re-request review button2 in the Reviewers tab.
Tip
If you have any comments about this review, please leave a message in the Add a comment section below and mention me with the @mateacademy-ai-mentor tag3.
I will read your message during my next review of your pull request. Please do not reply directly to my comments, as that feature is not supported yet.
Caution
Do not close the pull request until the review is complete. Closing it early can lead to unexpected behavior and disrupt the review process.
Footnotes
| {/* And remove commented lines :) */} | ||
| <Sum a={2} b={3} /> | ||
| <Sum a={-5} b={5} /> | ||
| <Sum a={10} b={0} /> |
There was a problem hiding this comment.
This passes b={0} explicitly, but the requirement states 'just a = 10' with no b prop. Remove the b prop and let the default value handle it.
| <Sum a={2} b={3} /> | ||
| <Sum a={-5} b={5} /> | ||
| <Sum a={10} b={0} /> | ||
| <Sum a={0} b={5} /> |
There was a problem hiding this comment.
This passes a={0} explicitly, but the requirement states 'just b = 5' with no a prop. Remove the a prop and let the default value handle it.
| <Sum a={-5} b={5} /> | ||
| <Sum a={10} b={0} /> | ||
| <Sum a={0} b={5} /> | ||
| <Sum a={0} b={0} /> |
There was a problem hiding this comment.
This passes both a={0} and b={0} explicitly, but the requirement states 'no params at all'. Remove both props entirely.
| import React from 'react'; | ||
| import { Sum } from './components/Sum/Sum'; | ||
| import './App.scss'; | ||
|
|
There was a problem hiding this comment.
Checklist item #2 requires using string interpolation inside the tag content. Replace the JSX expression concatenation with a template literal: {Sum of ${a} and ${b} is ${a + b}}.
| <p> | ||
| Sum of {a} and {b} is {a + b} |
There was a problem hiding this comment.
This violates checklist item #2 which requires using string interpolation inside tag content. Replace with template literal syntax using backticks.
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Sorry, the pull request review was unsuccessful for the following reasons:
Warning
No changes were made in the pull request since the last review. Please make sure that you have added files to the pull request and committed the changes.
[CODE: NCM]
If the issue is within your control, please address it.
The next review attempt will automatically launch in about 1 hour.
If you believe this is an error or need assistance, please contact the support team.
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your implementation is complete and fully satisfies all requirements. The Sum component correctly uses a named export with default values for both a and b set to 0, and the App component properly renders all five required instances using string interpolation as specified. All checklist items are satisfied, including writing tags with fewer than 3 attributes on a single line and using template literals for the paragraph content. Great work on addressing the previous issues and delivering a clean solution!
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
https://azesmmisha.github.io/react_sum/