@trbl/react-window-info

1.2.2 • Public • Published

NPM Bundle Size Supported by TRBL

React Window Info

Lorem ipsum

Highlights

  • Lorem ipsum

    Lorem ipsum

Quick Start

Installation

$ npm i @trbl/react-window-info
$ # or
$ yarn add @trbl/react-window-info

Composition

  import React from 'react';
  import {
    WindowInfo,
    WindowInfoProvider,
    withWindowInfo,
    useWindowInfo
  } from '@trbl/react-window-info';

  const WithWindowInfo = withWindowInfo(({ windowInfo }) => <div>{windowInfo}</div>);
  const UseWindowInfo = () => <div>{useWindowInfo()}</div>;

  const App = () => (
    <WindowInfoProvider>
      <WithWindowInfo />
      <UseWindowInfo />
      <WindowInfo>
        {(windowInfo) => <div>{windowInfo}</div>}
      <WindowInfo>
    </WindowInfoProvider>
  );

  export default App;

For working examples, see the demo app.

Demo

$ git clone git@github.com:trouble/react-window-info.git
$ yarn
$ yarn dev
$ open http://localhost:3000

Documentation

Contribution

Help us, or let us help you help us.

License

MIT Copyright (c) TRBL, LLC

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.2.2
    1
    • latest

Version History

Package Sidebar

Install

npm i @trbl/react-window-info

Weekly Downloads

1

Version

1.2.2

License

MIT

Unpacked Size

23.3 kB

Total Files

5

Last publish

Collaborators

  • chrishomsey
  • jacobsfletch
  • trouble