Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/streamich/libreact

Collection of useful React components
https://github.com/streamich/libreact

Last synced: about 2 months ago
JSON representation

Collection of useful React components

Awesome Lists containing this project

README

        

![libreact logo](./docs/assets/libreact.png)

# libreact

[![][npm-badge]][npm-url] [![][travis-badge]][travis-url] [![React Universal Interface](https://img.shields.io/badge/React-Universal%20Interface-green.svg)](https://github.com/streamich/react-universal-interface) [![Backers on Open Collective](https://opencollective.com/libreact/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/libreact/sponsors/badge.svg)](#sponsors)

React standard libraryโ€”must-have toolbox for any React project.

- [__LAUNCH STORYBOOK__](https://streamich.github.io/libreact/demos/) ๐Ÿš€
- [__See documentation__](https://streamich.github.io/libreact/en/)
- Most components implement [![React Universal Interface](https://img.shields.io/badge/React-Universal%20Interface-green.svg)](https://github.com/streamich/react-universal-interface)
- *Isomorphic* - most components work in browser and on server (and some in `react-native`).

## Installation


npm i libreact --save

## Usage

Library is modularโ€”you can import each component by its name.

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

const MyComponent = mock();
```

## Contents

- [Introduction](./docs/en/Introduction.md)
- [Dummies](./docs/en/Dummies.md)
- [`mock()`](./docs/en/mock.md) and [`loadable()`](./docs/en/loadable.md) โ€” [**example**](https://codesandbox.io/s/j2ovpr03z3)
- [`lazy()`](./docs/en/lazy.md) and [`delayed()`](./docs/en/delayed.md)
- [Inversion](./docs/en/Inversion.md)
- [``](./docs/en/State.md) and [`withState()`](./docs/en/State.md#withstate-hoc)
- [``](./docs/en/Toggle.md), [`withToggle()`](./docs/en/Toggle.md#withtoggle-hoc), and [`@withToggle`](./docs/en/Toggle.md#withtoggle-decorator) โ€” [**example**](https://codesandbox.io/s/zwkl16vv93)
- [``](./docs/en/Flipflop.md), [`withFlipflop()`](./docs/en/Flipflop.md#withflipflop-hoc), and [`@withFlipflop`](./docs/en/Flipflop.md#withflipflop-decorator)
- [``](./docs/en/Value.md), [`withValue()`](./docs/en/Value.md#withvalue-hoc), and [`@withValue`](./docs/en/Value.md#withvalue-decorator)
- [``](./docs/en/Counter.md), [`withCounter()`](./docs/en/Counter.md#withcounter-hoc) and [`@withCounter`](./docs/en/Counter.md#withcounter-decorator)
- [``](./docs/en/List.md), [`withList()`](./docs/en/List.md#withlist-hoc), and [`@withList`](./docs/en/List.md#withlist-decorator)
- [``](./docs/en/Map.md), [`withMap()`](./docs/en/Map.md#withmap-hoc), and [`@withMap`](./docs/en/Map.md#withmap-decorator)
- [``](./docs/en/ShouldUpdate.md), [`shouldUpdate()`](./docs/en/ShouldUpdate.md#shouldupdate-hoc), and [`pure()`](./docs/en/pure.md)
- [``](./docs/en/Lifecycles.md)
- [`invert()`](./docs/en/invert.md) and [``](./docs/en/invert.md#inverted)
- [Sensors](./docs/en/Sensors.md)
- [``](./docs/en/ActiveSensor.md), [`withActive()`](./docs/en/ActiveSensor.md#withactive-hoc), and [`@withActive`](./docs/en/ActiveSensor.md#withactive-decorator)
- [``](./docs/en/BatterySensor.md), [`withBattery()`](./docs/en/BatterySensor.md#withbattery), and [`@withBattery`](./docs/en/BatterySensor.md#withbattery-1)
- [``](./docs/en/ExitSensor.md) โ€” [**example**](https://codesandbox.io/s/7437x10z71)
- [``](./docs/en/FocusSensor.md), [`withFocus()`](./docs/en/FocusSensor.md#withfocus-hoc), and [`@withFocus`](./docs/en/FocusSensor.md#withfocus-decorator)
- [``](./docs/en/GeoLocationSensor.md), [`withGeoLocation()`](./docs/en/GeoLocationSensor.md#withgeolocation-hoc), and [`@withGeoLocation`](./docs/en/GeoLocationSensor.md#withgeolocation-decorator)
- [``](./docs/en/HoverSensor.md), [`withHover()`](./docs/en/HoverSensor.md#withhover-hoc), and [`@withHover`](./docs/en/HoverSensor.md#withhover-decorator) โ€” [**example**](https://codesandbox.io/s/8p3xqx83p9)
- [``](./docs/en/IdleSensor.md), [`withIdle()`](./docs/en/IdleSensor.md#withidle-hoc), and [`@withIdle`](./docs/en/IdleSensor.md#withidle-decorator)
- [``](./docs/en/MediaDeviceSensor.md), [`withMediaDevices()`](./docs/en/MediaDeviceSensor.md#withmediadevices), and [`@withMediaDevices`](./docs/en/MediaDeviceSensor.md#withmediadevices-1)
- [``](./docs/en/MediaSensor.md), [`withMedia()`](./docs/en/MediaSensor.md#withmedia), and [`@withMedia`](./docs/en/MediaSensor.md#withmedia-1)
- [``](./docs/en/MotionSensor.md), [`withMotion()`](./docs/en/MotionSensor.md#withmotion-hoc), and [`@withMotion`](./docs/en/MotionSensor.md#withmotion-decorator)
- [``](./docs/en/MouseSensor.md), [`withMouse()`](./docs/en/MouseSensor.md#withmouse-hoc), and [`@withMouse`](./docs/en/MouseSensor.md#withmouse-decorator) โ€” [**example**](https://codesandbox.io/s/k3o16j7n47)
- [``](./docs/en/NetworkSensor.md), [`withNetwork()`](./docs/en/NetworkSensor.md#withnetwork-hoc), and [`@withNetwork`](./docs/en/NetworkSensor.md#withnetwork-decorator)
- [``](./docs/en/LightSensor.md), [`withLight()`](./docs/en/LightSensor.md#withlight-hoc), and [`@withLight`](./docs/en/LightSensor.md#withlight-decorator)
- [``](./docs/en/LocationSensor.md), [`withLocation()`](./docs/en/LocationSensor.md#withlocation-hoc), and [`@withLocation`](./docs/en/LocationSensor.md#withlocation-decora)
- [``](./docs/en/OrientationSensor.md), [`withOrientation()`](./docs/en/OrientationSensor.md#withorientation-hoc), and [`@withOrientation`](./docs/en/OrientationSensor.md#withorientation-decorator)
- [``](./docs/en/ScratchSensor.md), [`withScratch()`](./docs/en/ScratchSensor.md#withscratch-hoc), and [`@withScratch`](./docs/en/ScratchSensor.md#withscratch-decorator)
- [``](./docs/en/ScrollSensor.md)
- [``](./docs/en/SizeSensor.md), [`withSize()`](./docs/en/SizeSensor.md#withsize-hoc), and [`@withSize`](./docs/en/SizeSensor.md#withsize-decorator) โ€” [**example**](https://codesandbox.io/s/0y2qjm210p)
- [``](./docs/en/WidthSensor.md), [`withWidth()`](./docs/en/WidthSensor.md#withwidth-hoc-and-withwidth-decorator), and [`@withWidth`](./docs/en/WidthSensor.md#withwidth-hoc-and-withwidth-decorator)
- [``](./docs/en/TouchSupportSensor.md)
- [``](./docs/en/ViewportSensor.md), [`withViewport()`](./docs/en/ViewportSensor.md#withviewport-hoc), and [`@withViewport`](./docs/en/ViewportSensor.md#withviewport-decorator)
- [``](./docs/en/ViewportSensor.md#viewportscrollsensor) and [``](./docs/en/ViewportSensor.md#viewportobserversensor)
- [``](./docs/en/WindowScrollSensor.md), [`withWindowScroll()`](./docs/en/WindowScrollSensor.md#withwindowscroll-hoc), and [`@withWindowScroll`](./docs/en/WindowScrollSensor.md#withwindowscroll-decorator)
- [``](./docs/en/WindowSizeSensor.md), [`withWindowSize()`](./docs/en/WindowSizeSensor.md#withwindowsize-hoc), and [`@withWindowSize`](./docs/en/WindowSizeSensor.md#withwindowsize-decorator)
- [``](./docs/en/WindowWidthSensor.md), [`withWindowWidth()`](./docs/en/WindowWidthSensor.md#withwindowwidth-hoc), and [`@withWindowWidth`](./docs/en/WindowWidthSensor.md#withwindowwidth-decorator)
- [Context](./docs/en/Context.md)
- [Google Sign-in for Websites](./docs/en/GoogleAuth.md)
- [``](./docs/en/Provider.md#provider), [``](./docs/en/Provider.md#consumer), [`withContext()`](./docs/en/Provider.md#withcontext-hoc), and [`@withContext`](./docs/en/Provider.md#withcontext-decorator)
- [``](./docs/en/theme.md#theme), [``](./docs/en/theme.md#themed), [`withTheme()`](./docs/en/theme.md#withtheme-hoc), and [`@withTheme`](./docs/en/theme.md#withtheme-decorator)
- [``](./docs/en/cssvars.md), [``](./docs/en/cssvars.md#cssvars), [`withCssVars()`](./docs/en/cssvars.md#withcssvars-hoc), and [`@withCssVars`](./docs/en/cssvars.md#withcssvars-decorator)
- [__Routing__](./docs/en/routing.md): [`createRouter()`](./docs/en/routing.md#createrouter), [``](./docs/en/routing.md#router), [``](./docs/en/routing.md#route), [``](./docs/en/routing.md#switch), [``](./docs/en/routing.md#match), [``](./docs/en/routing.md#link), and [`go()`](./docs/en/routing.md#go)
- [``](./docs/en/translate.md#translations), [``](./docs/en/translate.md#translate-or-t), [``](./docs/en/translate.md#translate-or-t), [`withT()`](./docs/en/translate.md#witht-hoc), and [`@withT`](./docs/en/translate.md#witht-decorator)
- [UI](./docs/en/UI.md)
- [``](./docs/en/Portal.md), [``](./docs/en/Overlay.md), and [``](./docs/en/Modal.md)
- [``](./docs/en/Dimmer.md) and [``](./docs/en/Dimmable.md)
- [``](./docs/en/Parallax.md)
- [``](./docs/en/FullScreen.md)
- [``](./docs/en/Slider.md)
- [``](./docs/en/DropArea.md)
- [``](./docs/en/Group.md)
- [``](./docs/en/InfiniteScroll.md)
- [``](./docs/en/OutsideClick.md)
- [``](./docs/en/Ripple.md) and [`withRipple()`](./docs/en/Ripple.md#withripple) โ€” [**example**](https://codesandbox.io/s/983q7jr80o)
- [``](./docs/en/Img.md)
- [``](./docs/en/ListTable.md)
- [``](./docs/en/WidthQuery.md), [``](./docs/en/View.md), [``](./docs/en/WindowWidthQuery.md), and [``](./docs/en/InlineWidthQuery.md)
- [``](./docs/en/Audio.md) and [``](./docs/en/Video.md)
- [``](./docs/en/Speak.md), [``](./docs/en/Vibrate.md), [``](./docs/en/Alert.md)
- [Animation](./docs/en/Animation.md)
- [``](./docs/en/AfterTimeout.md), [``](./docs/en/AfterDraf.md), and [``](./docs/en/WhenIdle.md)
- [``](./docs/en/Render.md), [`withRender()`](./docs/en/Render.md#withrender-hoc), and [`@withRender`](./docs/en/Render.md#withrender-decorator)
- [``](./docs/en/RenderInterval.md), [`withRenderInterval()`](./docs/en/RenderInterval.md#withrenderinterval-hoc), and [`@withRenderInterval`](./docs/en/RenderInterval.md#withrenderinterval-decorator)
- [``](./docs/en/Tween.md), [`withTween()`](./docs/en/Tween.md#withtween-hoc), and [`@withTween`](./docs/en/Tween.md#withtween-decorator)
- [``](./docs/en/Interpolation.md), [`withInterpolation()`](./docs/en/Interpolation.md#withinterpolation-hoc), and [`@withInterpolation`](./docs/en/Interpolation.md#withinterpolation-decorator)
- [Side Effects](./docs/en/Side-effects.md)
- [``](./docs/en/LocalStorage.md)
- [``](./docs/en/ClassNames.md)
- [Boundaries](./docs/en/Boundaries.md)
- [``](./docs/en/BrowserOnly.md), [``](./docs/en/ServerOnly.md), and [``](./docs/en/ElectronOnly.md)
- [``](./docs/en/ErrorBoundary.md) and [`withErrorBoundary()`](./docs/en/ErrorBoundary.md#witherrorboundary-hoc)
- ``
- [NEXT](./docs/en/next.md)
- [`createRef()`](./docs/en/next/createRef.md), [`createState()`](./docs/en/next/createState.md), and [`createLifecycleEvents()`](./docs/en/next/createLifecycleEvents.md)
- Other
- [``](./docs/en/Resolve.md)
- [``](./docs/en/Sms.md), [``](./docs/en/Mailto.md)
- [`getDisplayName()`](./docs/en/getDisplayName.md)
- [`touchSupported()`](./docs/en/TouchSupportSensor.md)

## Contributors

This project exists thanks to all the people who contribute.

## Backers

Thank you to all our backers! ๐Ÿ™ [[Become a backer](https://opencollective.com/libreact#backer)]

## Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/libreact#sponsor)]










## License

[Unlicense](./LICENSE) โ€” public domain.

[npm-url]: https://www.npmjs.com/package/libreact
[npm-badge]: https://img.shields.io/npm/v/libreact.svg
[travis-url]: https://travis-ci.org/streamich/libreact
[travis-badge]: https://travis-ci.org/streamich/libreact.svg?branch=master