Skip to content
Justice Tech School

Expressions in JSX

Curly braces embed any JavaScript expression in markup.

Example
function Hello() {
  const name = "Ada";
  return <p>Hello {name.toUpperCase()}, 2 + 2 = {2 + 2}</p>;
}

Exercise

Embed a value.

<p>{}</p>

Quiz Test

What do curly braces hold?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.