Polished
polished
A lightweight toolset for writing styles in Javascript.
Animation
styled-components
polished
emotion
glamor
css-in-js
inline-styles
react
flow
typescript
color manipulate
Stars
849
Weekly
9.4M
Open issues
11
Bundle
~15 kB
Installation
npm install polishedCode example
import { motion } from "polished";
export function Example() {
return (
<motion.div
initial={{ opacity: 0, y: 12 }}
animate={{ opacity: 1, y: 0 }}
transition={{ duration: 0.35 }}
>
<h2>Animated with Polished</h2>
</motion.div>
);
}Pros & cons
Pros
- Actively maintained by Brian Hough
- 9.4M weekly downloads. Battle tested
- First-class TypeScript definitions
- MIT licensed
Considerations
- Adds roughly ~15 kB to your bundle
- Needs client-only rendering in SSR frameworks
- Not supported in React Native
- 11 open issues on GitHub