@avinlab/react-size-me

1.1.5 • Public • Published

react-size-me

React component to determine parent container size

NPM registry NPM license

Demo

Here is an examples page

Install

# Yarn
yarn add @avinlab/react-size-me

# NPM
npm install --save @avinlab/react-size-me

Usage

import React from 'react';
import SizeMe from '@avinlab/react-size-me';

<div className="container">
    <SizeMe>
        {({ width, height }) => (
            <div className="inner" style={{ width, height }}/>                
        )}
    </SizeMe>
</div>

License

MIT © avin

Package Sidebar

Install

npm i @avinlab/react-size-me

Weekly Downloads

5

Version

1.1.5

License

MIT

Unpacked Size

14.7 kB

Total Files

8

Last publish

Collaborators

  • carcinogen75