Pseudo class selector doubt

I am mot able to understand root pseudo class selector

1 Like

Hello @AdityaWhiteHat. Welcome to the FCC forums.
The ::root pseudo-class selector selects the uppermost element (the wrapper of entire HTML code). It is popularly used for assigning CSS variables so that when we use that CSS variable, it will have global scope (usable anywhere in the document).
Hope you understand.

1 Like

Thank you paulsonstech

1 Like