react-responsive-type

0.0.2 • Public • Published

React Responsive Text

is a high order wrapper based on http://simplefocus.com/flowtype/

Usage

Just import and wrap with your desired settings

 
import ReactResponsiveText from 'react-responsive-type';
...
 
class SomeApp extends Component{
  ...
}
 
export default ReactResponsiveText(SomeApp,{
  minimum: 500,
  maximum: 1200
});

Settings

  • minimum: The minimum element width text will stop being resize
  • maximum: The minimum element width text will stop being resize
  • minFont: The minimum font size that the element will be resized to
  • maxFont: The maximum font size that the element will be resized to
  • fontRatio: When using your own font-size use this setting to adjust font sizes(bigger numbers will make the font smaller and vice versa)

Issues / PR

If you found any issue with this module, please let me know.

Thanks

Package Sidebar

Install

npm i react-responsive-type

Weekly Downloads

1

Version

0.0.2

License

MIT

Last publish

Collaborators

  • jellykid