npm.io
0.1.19 • Published 2 years ago

@types/react-intl-redux

Licence
MIT
Version
0.1.19
Deps
3
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/react-intl-redux

Summary

This package contains type definitions for react-intl-redux (https://github.com/ratson/react-intl-redux).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-intl-redux.

index.d.ts

import { IntlProvider as ReactIntlProvider } from "react-intl";
import { Provider as ReduxProvider } from "react-redux";
import { Action, AnyAction } from "redux";

interface IntlState {
    locale: string;
    messages: any;
    formats?: any;
}

interface IntlAction extends Action {
    payload?: IntlState | undefined;
}

export function intlReducer(state: IntlState | undefined, action: IntlAction): IntlState;
export function updateIntl(opts: IntlState): IntlAction;
export class IntlProvider extends ReactIntlProvider {}
export class Provider<A extends Action = AnyAction> extends ReduxProvider<A> {}

Additional Details

Credits

These definitions were written by Karol Janyst.