Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

libreact

streamich2.2k2.13.3TypeScript support: included

React standard library

react, lib, libreact, stdlib, hoc, higher-order, composition, facc, components, utilities, toolbox, toolbox, dummies, mock, mocks, loadable, lazy, delayed, viewport, inversion, invert, state, toggle, flipflop, list, map, sensor, sensors, battery, geolocation, location, hover, media, motion, mouse, network, light, orientation, scroll, size, intersection, observer, context, provider, consumer, routing, router, route, theming, theme, translation, internationalization, audio, video, localstorage, speak, vibrate, sms, mailto, link, fullscreen, css, reset, portal, overlay, modal

readme

libreact logo

libreact

React Universal Interface Backers on Open Collective Sponsors on Open Collective

React standard library—must-have toolbox for any React project.

Installation

npm i libreact --save

Usage

Library is modular—you can import each component by its name.

import {mock} from 'libreact/lib/mock';
// or
import {mock} from 'libreact/modules/mock';

const MyComponent = mock();

Contents

Contributors

This project exists thanks to all the people who contribute.

Backers

Thank you to all our backers! 🙏 [Become a backer]

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]

License

Unlicense — public domain.

changelog

2.13.3 (2020-06-15)

Bug Fixes

  • 🐛 update tslib dependency (7be746b)

2.13.2 (2019-09-23)

Bug Fixes

  • 🐛 call .laodMore() on multiple short pages (fe73c91)

2.13.1 (2019-04-05)

Bug Fixes

  • 🐛 call <Modal> onElement from componentDidMount (95fd86f)

2.13.0 (2019-04-04)

Features

  • 🎸 don't blur elements with data-modal-ignore attribute (718c1df)

2.12.2 (2019-02-12)

Bug Fixes

  • typo in LocalStorage.md (ff1c8a8)

2.12.1 (2019-02-08)

Bug Fixes

  • example referred to incorrect component (cfa0671)

2.12.0 (2019-02-05)

Bug Fixes

  • 🐛 avoide React use "key" warnings (66fad9b)

Features

  • 🎸 add <ListTable> component (c9d767a)
  • 🎸 improve <ListTable> and add reference to docs (d95444d)

2.11.0 (2019-01-27)

Features

  • 🎸 add polling to scroll sensor and infinite scroll (dbc5646)

2.10.1 (2018-12-30)

Bug Fixes

  • 🐛 fix <Route> and <Match> data type (cd51a81)

2.10.0 (2018-12-25)

Bug Fixes

  • 🐛 fix <ViewportObserverSensor> when threshold not spec (a486bec)
  • 🐛 improve viewport sensors and speed up Storybook (16d1603)

Features

  • 🎸 add <InfiniteScroll> component (0768958)
  • 🎸 preload items 100px before the reach end (cb2990b)
  • 🎸 use window resize in ViewportScrollSensor (9004447)

2.9.3 (2018-12-22)

Bug Fixes

  • snapshot must be object or null (a1eaca6)

2.9.2 (2018-12-22)

Bug Fixes

2.9.1 (2018-12-22)

Bug Fixes

  • define shouldUpdate function (2277cfe)
  • ensure we always return boolean from shouldComponentUpdate (f2776ab)

2.9.0 (2018-12-22)

Features

  • 🎸 improve <Lifecycles> component (baae6ea)

2.8.1 (2018-11-20)

Bug Fixes

  • 🐛 fire onMount event before attempting to play video (cde669a)
  • 🐛 remove testing code (ac8c487)

2.8.0 (2018-11-20)

Features

  • 🎸 reset
  • 🎸 track canPlay boolean in state of

2.7.0 (2018-11-15)

Bug Fixes

Features

  • 🎸 prevent window scroll under <Overlay> (11b3a97)

2.6.0 (2018-10-22)

Features

  • release <OutsideClick> clickRoots() (4fdc4e7)

2.5.0 (2018-10-20)

Features

  • TouchSupportSensor: Add the TouchSupportSensor HOC and func (a06fbed)

2.4.0 (2018-10-12)

Features

  • 🎸 improve props typings of <WindowScrollSensor> (090c2bb)

2.3.0 (2018-10-12)

Bug Fixes

  • 🐛 loosen render prop types (392214e)

Features

  • 🎸 add universal component typings (f725230)

2.2.1 (2018-10-06)

Bug Fixes

  • 🐛 add typings to build artifacts (28812cc)

2.2.0 (2018-10-03)

Bug Fixes

  • 🐛 export CssVars using correc casing (b46164f)

Features

  • 🎸 export EsNext modules (1805455)
  • 🎸 export TypeScript types and improve build process (c050afd)

Performance Improvements

  • ⚡️ upgrade throttle-debounce lib, fix tests after refactor (a8da481)

2.1.0 (2018-09-30)

Bug Fixes

  • 🐛 simplify AfterDraf component (5d71134)

Features

  • 🎸 add GoogleAuthButton scaffolding (b22fb0a)
  • 🎸 implement Google auth Provider and Consumer components (ece3676)

2.0.1 (2018-06-28)

Bug Fixes

  • 🐛 fix .setState() warning in <MediaSensor> constructor (4a7b515)
  • 🐛 fix new TypeScript errors (f3e9529)

2.0.0 (2018-06-09)

Features

BREAKING CHANGES

  • bump version to v2

1.0.0 (2018-06-09)

Bug Fixes

  • .tsx -> .ts so <WindowWidthQuery> is in build (f2e6066)
  • 🐛 include React correctly (36ed884)
  • add state to <WidthSensor> (73824ab)
  • allow setting max distance (89b910c)
  • allow to set only boolean (8e23e1c)
  • fix .onElement event (576e6ff)
  • fix <MediaSensor> event handling (ac2d04e)
  • fix build include .tsx files in output (218e0d3)
  • fix CSS resets after dep update (f64b2fa)
  • fix gulpfile build location (c74f736)
  • fix gulpfile build paths (0ea10f3)
  • fix repo address (a22254f)
  • localStorage can throw, wrap in try block (2ee63a7)
  • make initial SizeSensor width Infinity (f6c5787)
  • remove redundant isClient checks (38c2fc9)
  • remove unused debounce() function (aed1ee9)
  • rename .tsx -> .ts (a7d6834)
  • reverse <ElectronOnly> logic (e55607f)
  • send event to onText callback (5546bdc)
  • set initial media muted value (55d9dd2)
  • universal render interface requires 2 args (422f677)
  • use .ts file (e9860c4)

Features

Performance Improvements

  • remove unnecessary regexp (f994f5d)

Tests

  • 💍 fix tests after context refactor and Enzyme update (f142450)

BREAKING CHANGES

  • release v2
  • moved to React 16 context API