css in js
WHY CSS-IN-JS
- JavaScript enhances the capabilities of CSS (e.g. nesting, automatic vendor-prefixing, unit testing—depending on the library).
- Selectors are locally scoped, as CSS-in-JS libraries generate unique class names so that you don’t have to worry about specificity collision.
- You can achieve better performance, as CSS-in-JS only loads styles that are currently in use.
CSS in JS library
- STYLED COMPONENTS
- EMOTION
- JSS