Skip to main content

Module: core/applyMiddleware

Functions

applyMiddleware

applyMiddleware(...args): typeof __class

Description

Apply middlewares for Redux.

Example

import logger from 'redux-logger';

@injectable()
class Foo {}

const app = createApp({
modules: [applyMiddleware(logger)],
main: Foo,
render: () => {},
});

Parameters

NameTypeDescription
...argsMiddleware<{}, any, Dispatch<AnyAction>>[]middlewares for Redux

Returns

typeof __class

Defined in

packages/reactant-module/src/core/applyMiddleware.ts:30