Releases: blakeembrey/react-free-style
Releases · blakeembrey/react-free-style
ES2015 Module Version
Added
- Export
module
version for tree-shaking
Remove `displayName` Argument
Changed
- Use
free-style@3
- Remove
displayName
param (use$displayName
infree-style@3
)
Normalize Allowed CSS Values
Fixed
- Normalize
CssValue
types to allow strings everywhere and support recursive CSS nested arrays
Support CSS Arrays
Added
- Support an array of CSS values and automatically "join" into multiple class names
Remove Deprecated APIs
Changed
- Simplify external API, remove deprecated methods
- Remove
createStyles()
function - Remove
composeStyle()
in favor of existingjoin(...)
utility - Add
useCss()
for using any CSS object, cachedcss()
object or computed functional style
- Remove
Added
- Allow
undefined
andstring
values as parameters tojoin(...)
utility
CSS property functions
Added
- Allow
css
property to accept functions, allows pre-computed styles - Expose
css()
helper function that precomputes styles (e.g. re-used incss
props or composition) - Expose
join()
helper for combining CSS functions (e.g. join style functions/objects over class names)
Compose Styles Before Registering Styles
Fixed
- Ensure composition of styles happens before registering new styles
Styled Composition
Added
- Support composition of
styled
components
Document Themes
Added
- Add documentation on how to do your own themes since it's built-in to React but usually abstracted away by other libraries
JSX Pragma and Defined Tags Support
Added
- Expose
jsx
pragma support for primitive types - Expose
tags
module for pre-defined HTML tags as components