paint-brush
REM and EM in CSS Explainedby@ali6nx404
120 reads

REM and EM in CSS Explained

by Mahesh Patidar 3mOctober 26th, 2021
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

Rem and em units in CSS create confusion for beginners. Em is relative to the font size of the parent of an element and rem is relative. Rem is only relative to its direct or nearest parent. Em becomes a trouble when you don't understand the relation between parents and child. Some people like to use rem units for consistency and scalability, while others like em units for places where the influence of nearby parent elements would make sense more than rem. Compounding effect of em is the power of compounding.

Companies Mentioned

Mention Thumbnail
Mention Thumbnail
featured image - REM and EM in CSS Explained
Mahesh Patidar  HackerNoon profile picture
Mahesh Patidar

Mahesh Patidar

@ali6nx404

Front-end Developer and Technical Writer.

About @ali6nx404
LEARN MORE ABOUT @ALI6NX404'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

Mahesh Patidar  HackerNoon profile picture
Mahesh Patidar @ali6nx404
Front-end Developer and Technical Writer.

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite
Also published here
Cyberfishnews
Cyberfishnews
Cyberfishnews
Cyberfishnews
Cyberfishnews
Nommu
Zotan