A React higher-order component for CSS-in-JavaScript that supports themes and multiple styling implementations.
react-with-styles is a React library that provides a unified API for CSS-in-JavaScript with theme support. It allows developers to write styles in JavaScript while remaining decoupled from specific CSS-in-JS implementations like Aphrodite or JSS. The library solves the problem of vendor lock-in by letting teams switch styling engines without refactoring component styles.
React developers and teams using CSS-in-JavaScript who need theme consistency and the flexibility to change styling libraries. It's particularly useful for large applications where maintaining style consistency across components is critical.
Developers choose react-with-styles because it offers theme management and implementation independence in one package. Its pluggable interface system and support for multiple CSS-in-JS libraries make it a future-proof choice for styling React applications.
Use CSS-in-JavaScript with themes for React without being tightly coupled to one implementation
Provides built-in theme access for colors, fonts, and units, enabling consistent design systems as shown in the example using color.primary.
Decouples styles from specific CSS-in-JS libraries via pluggable interfaces, allowing switches between Aphrodite, JSS, or React Native without code changes.
Offers multiple usage patterns including a higher-order component, a hook, and decorator syntax, catering to different React coding styles.
Integrates seamlessly with react-with-direction for LTR/RTL contexts, making it suitable for internationalized applications.
The project is in maintenance mode and will be archived, meaning no new features, bug fixes, or long-term support, as stated in the README.
Requires registering themes and choosing separate interface packages, adding configuration overhead compared to integrated solutions like styled-components.
Supports a deprecated ThemedStyleSheet singleton that will be removed, forcing migration to the context-based API for future compatibility.
Fast, expressive styling for React. Server components, client components, streaming SSR, React Native—one API.
Full CSS support for JSX without compromises
JSS is an authoring tool for CSS which uses JavaScript as a host language.
Framework-agnostic CSS-in-JS with support for server-side rendering, browser prefixing, and minimum CSS generation
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.