Skip to main content

Overview

The React Event Storm is providing a lightweight, minimal abstraction for the Event Storm library.

Technical stack

  • React ^16.8.0(hooks support)

Installation

To install the library run:

# npm
npm i react-event-storm

# yarn
yarn add react-event-storm
Required dependency

The library is using Event Storm as a peer dependency, so you need to install it.

Simple example

import { createStorm } from 'event-storm';
import { useStorm } from 'react-event-storm';

const defaultState = {
name: 'React Event Storm',
}

const storm = createStorm(defaultState);

function Component() {
const { name } = useStorm(storm);
return <span>This is {name}</span>
}

See it in action

Examples: