react-free-style

Make React components easier and more maintainable by using inline style objects

MIT License

Downloads
723
Stars
139
Committers
8

Bot releases are hidden (Show)

react-free-style - Styled Forward Ref

Published by blakeembrey over 5 years ago

Changed

  • Forward refs to styled component automatically
react-free-style - Styled Component

Published by blakeembrey over 5 years ago

Added

  • Support styled(type, style) signature for component, e.g. Button = styled('button', { color: 'red' })
react-free-style - React Hooks

Published by blakeembrey almost 6 years ago

Changed

  • Use React hooks for creating styles
  • Use React context for rendering CSS
react-free-style - Style Helper

Published by blakeembrey over 6 years ago

Fixed

  • style-helper needs to be a dependency

Note: This was a user error. I accidentally did npm i -D which moved it to devDependencies, but npm i -S didn't move it back to a regular dependency. I should have verified it worked as expected before releasing 7.0.1.

react-free-style - React Peer Dependency

Published by blakeembrey over 6 years ago

Added

  • Specify peer dependency on react

Fixed

  • Updated README documentation
react-free-style - Merged Style Sheet

Published by blakeembrey almost 7 years ago

Changed

  • Back to a merged style sheet by using insertRule and deleteRule at runtime
  • HOC styles and Style have moved to the wrapped component (e.g. withStyles(Component).Style) since the styles will now use the component name as part of the class name (greater usefulness when debugging where a style comes from)
react-free-style - `withFreeStyle`

Published by blakeembrey about 7 years ago

Changed

  • wrap and styled now accept a withFreeStyle boolean argument to get an inline free-style instance
  • <style /> element runtime changes - now using multiple <style /> elements per active free-style instance
react-free-style - Component Will Update

Published by blakeembrey about 7 years ago

Fixed

  • Enable componentWillUpdate fixes for hot code reloading
  • Correct order of unmount and unmerge styles when unmounting a component
react-free-style - Update `style-helper`

Published by blakeembrey about 7 years ago

Changed

  • Support rules using tuples
react-free-style - `styled()` Options

Published by blakeembrey about 7 years ago

Fixed

  • Forgot to pass options into registerStyleSheet - tested properly now
react-free-style - Register Style Sheet Updates

Published by blakeembrey about 7 years ago

Changed

  • Update registerStyleSheet to support functions and options (from style-helper)
  • Merge props.styles when using the styled() component
  • Remove the directly exported create() component - shouldn't be needed directly (use styled() or wrap()) but is still available as FreeStyle.create()
react-free-style - Style Sheet `displayName`

Published by blakeembrey about 7 years ago

Added

  • Use style sheet properties as displayName for easier debugging

image

react-free-style - Hot Code Reloading

Published by blakeembrey about 7 years ago

Fixed

  • Expose componentWillUpdate to detect changes to Style and mount new styles
react-free-style - Fix `styled().Style`

Published by blakeembrey over 7 years ago

Changed

  • This was documented as styled().Style but it was exposed as styled()(Component).Style - the functionality has been fixed to match the documentation as that seems like the most logical use-case (access it when you need imperative access to free-style, which means you need the results before Component is defined)
react-free-style - Default `styled` style sheet object

Published by blakeembrey over 7 years ago

Changed

  • Allow the styleSheet argument for styled to be undefined
react-free-style - Expose `displayName` and `registerStyleSheet` Helper

Published by blakeembrey over 7 years ago

Added

  • Add displayName properties to stateless components
  • Expose registerStyleSheet helper used in styled
react-free-style - Expose `styled` Function

Published by blakeembrey over 7 years ago

Added

  • Expose a styled(styles)(component) helper in the style of redux and apollo
react-free-style - Update Free-Style

Published by blakeembrey over 7 years ago

Changed

  • Bumped the minor version of free-style
react-free-style - Remodel `Style`

Published by blakeembrey about 8 years ago

Changed

  • No more StyleElement to render in DOM, automatically appends to document.head instead
  • Implement rewind() and peek() exported methods modelled from https://github.com/nfl/react-helmet (used for server-side rendering only)

P.S. If you were doing something cool with the multiple <style /> elements, please let me know!

react-free-style - Pass `this.props`

Published by blakeembrey about 8 years ago

Fixed

  • Pass this.props instead of input to child component as HOC