Curly braces { } are special syntax in JSX. It is used to evaluate a JavaScript expression during compilation. A JavaScript expression can be a variable, function, an object, or any code that resolves into a value.

Let’s take an example.


 const greenStyle={color: 'green'} 
<Box style={greenStyle} />


which is the same as

<Box style={‌{color: 'green'}} />