Skip to content

Soluiton#4205

Open
protocolo23 wants to merge 1 commit intomate-academy:masterfrom
protocolo23:develop
Open

Soluiton#4205
protocolo23 wants to merge 1 commit intomate-academy:masterfrom
protocolo23:develop

Conversation

@protocolo23
Copy link
Copy Markdown

Copy link
Copy Markdown

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

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

Review Summary

Your solution is approved as an educational override so you can keep progressing while learning, even though there are a couple of small style issues to address.

You correctly implemented the core requirements: Sum is a named export, it uses default values for a and b, and App.jsx renders the five required Sum components using concise one-line JSX where appropriate. The main style issue is in src/components/Sum/Sum.jsx and src/App.jsx on the line with <p>Sum of {a} and {b} is {a + b}</p>, which conflicts with [CHECKLIST ITEM #2] Use string interpolation inside tag content. To fix this, rewrite that line to use a single template literal inside braces, for example: <p>{Sum of ${a} and ${b} is ${a + b}}</p>. As a minor improvement, remove any leftover commented-out code in Sum.jsx so the file stays clean and focused. Overall, your functional work is strong, and tightening up these stylistic details will bring your code fully in line with the checklist.


✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨

Footnotes

  1. Rate AI review example

// export const Sum = () => ();
export const Sum = ({ a = 0, b = 0 }) => (
<p>
Sum of {a} and {b} is {a + b}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This violates [CHECKLIST ITEM #2] "Use string interpolation inside tag content" — the paragraph uses multiple JSX expressions (Sum of {a} and {b} is {a + b}) instead of a single template string. Consider changing the content to use a template literal, e.g. <p>{Sum of ${a} and ${b} is ${a + b}}</p>.

Comment thread src/App.jsx
import React from 'react';
import './App.scss';
import { Sum } from './components/Sum/Sum';

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This violates checklist item #2: "Use string interpolation inside tag content" — the paragraph currently uses separate text and expression insertions (Sum of {a} and {b} is {a + b}). Consider using a template literal inside braces, e.g. <p>{Sum of ${a} and ${b} is ${a + b}}</p> to match the required style.

Copy link
Copy Markdown

@raulriato raulriato left a comment

Choose a reason for hiding this comment

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

As the mentor AI suggested, you're not rendering the Sum.jsx the way it's supposed to. But, since it's not a major problem, I'll approve the task.

@protocolo23
Copy link
Copy Markdown
Author

As the mentor AI suggested, you're not rendering the Sum.jsx the way it's supposed to. But, since it's not a major problem, I'll approve the task.

Thanks for the feedback. I’ll make sure to fix the issue with the Sum.jsx as Like requested.

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