Key Concepts

Review core concepts you need to learn to master this subject

The css Prop

// object styles <div css={{ backgroundColor: 'rebeccapurple', }} > Content to Display </div> // tagged template literals <div css={css` background-color: rebeccapurple; `} > Content to Display </div>

In Emotion, the css prop is used to style elements. It can be used with object styles and tagged template literals.

How you'll master it

Stress-test your knowledge with quizzes that help commit syntax to memory

Pro Logo