react-scalable
v0.0.2
Published
Fit the content
Downloads
7
Readme
Respect Scalable.
Demo
https://abouthiroppy.github.io/react-scalable
Install
$ npm i --save react-scalable
Usage
import React from 'react';
import Scalable from 'react-scalable';
const Component = () => (
<Scalable>
<h1>Hello!</h1>
</Scalable>
);
Props
| Name | Default | Type | Description | | ------------- | ------------- | ------------- | ------------- | | align | center | center | left | right | An element's horizontal alignment | | verticalAlign | center | center | top | bottom | An element's vertical alignment | |containerHeight|fixed| fixed | auto| whether the element is fitted within content | |minScale| N/A | number | an element's minimum scale | |maxScale| N/A | number | an element's maximum scale |
Development
$ npm i
$ npm start # start storybook
$ open http://localhost:8080