0.9.1 • Published 4 years ago
@redux-tools/middleware-react v0.9.1
@redux-tools/middleware-react
React bindings for the @redux-tools/middleware package.
API Reference
withMiddleware
Creates a component decorator which handles the lifecycle of passed middleware, mounting and unmounting them automatically. The namespace of the middleware is determined based on React context.
Arguments
middleware
(Object): The middleware to use.options
(Object): Options for the decorator. Possible options:isGlobal: boolean
,isPersistent: boolean
,feature: string
, andnamespace: string
.
Returns
(Function): A component decorator.
Example
import React from 'react';
import { withMiddleware } from '@redux-tools/middleware-react';
import { someMiddleware } from './middleware';
const Container = () => null;
export default withMiddleware({ someMiddleware })(Container);
<Provider />
See injectors-react for more info.
0.9.1
4 years ago
0.8.2
4 years ago
0.8.1
4 years ago
0.8.0
4 years ago
0.7.0
4 years ago
0.6.0
5 years ago
0.5.0
5 years ago
0.5.0-alpha.4
5 years ago
0.5.0-alpha.3
5 years ago
0.5.0-alpha.2
5 years ago
0.5.0-alpha.1
5 years ago
0.5.0-alpha.0
5 years ago
0.4.0
5 years ago