@types/react-router-redux
TypeScript definitions for react-router-redux
Last updated 9 years ago by types .
MIT · Repository · Original npm · Tarball · package.json
$ cnpm install @types/react-router-redux 
SYNC missed versions from official npm registry.

Installation

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

Summary

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

Details

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

index.d.ts

// Type definitions for react-router-redux 5.0
// Project: https://github.com/reactjs/react-router-redux
// Definitions by: Huy Nguyen <https://github.com/huy-nguyen>
//                 Shoya Tanaka <https://github.com/8398a7>
//                 Mykolas <https://github.com/mykolas>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 3.0

import {
    Store,
    Dispatch,
    Middleware,
    Reducer
} from 'redux';
import {
    History,
    Location,
    Path,
    LocationState,
    LocationDescriptor
} from 'history';
import * as React from 'react';
import { match } from 'react-router';

export interface ConnectedRouterProps<State> {
    children?: React.ReactNode;
    store?: Store<State> | undefined;
    history: History;
}
export class ConnectedRouter<State> extends React.Component<ConnectedRouterProps<State>> {}

export const LOCATION_CHANGE = '@@router/LOCATION_CHANGE';

export interface RouterState {
    location: Location | null;
}

export const routerReducer: Reducer<RouterState>;

export const CALL_HISTORY_METHOD = '@@router/CALL_HISTORY_METHOD';

export function push(location: LocationDescriptor, state?: LocationState): RouterAction;
export function replace(location: LocationDescriptor, state?: LocationState): RouterAction;
export function go(n: number): RouterAction;
export function goBack(): RouterAction;
export function goForward(): RouterAction;

export const routerActions: {
    push: typeof push
    replace: typeof replace
    go: typeof go
    goBack: typeof goBack
    goForward: typeof goForward
};

export interface LocationActionPayload {
    method: string;
    args?: any[] | undefined;
}

export interface RouterAction {
    type: typeof CALL_HISTORY_METHOD;
    payload: LocationActionPayload;
}

export interface LocationChangeAction {
    type: typeof LOCATION_CHANGE;
    payload: Location & {
        props?: {
            match: {
                path: string;
                url: string;
                params: any;
                isExact: boolean;
            },
            location: Location;
            history: History;
        } | undefined
    };
}

export function routerMiddleware(history: History): Middleware;

export function createMatchSelector(path: string): (state: { router: RouterState }) => match | null;

Additional Details

Credits

These definitions were written by Huy Nguyen, Shoya Tanaka, and Mykolas.

Current Tags

  • 5.0.21                                ...           latest (4 years ago)
  • 4.0.38                                ...           ts2.0 (9 years ago)
  • 4.0.44                                ...           ts2.1 (9 years ago)
  • 5.0.2                                ...           ts2.2 (9 years ago)
  • 5.0.9                                ...           ts2.3 (8 years ago)
  • 5.0.11                                ...           ts2.4 (8 years ago)
  • 5.0.11                                ...           ts2.5 (8 years ago)
  • 5.0.13                                ...           ts2.6 (8 years ago)
  • 5.0.13                                ...           ts2.7 (8 years ago)
  • 5.0.16                                ...           ts2.8 (8 years ago)
  • 5.0.16                                ...           ts2.9 (8 years ago)
  • 5.0.18                                ...           ts3.0 (7 years ago)
  • 5.0.18                                ...           ts3.1 (7 years ago)
  • 5.0.18                                ...           ts3.2 (7 years ago)
  • 5.0.18                                ...           ts3.3 (7 years ago)
  • 5.0.18                                ...           ts3.4 (7 years ago)
  • 5.0.18                                ...           ts3.5 (7 years ago)
  • 5.0.19                                ...           ts3.6 (5 years ago)
  • 5.0.20                                ...           ts3.7 (5 years ago)
  • 5.0.21                                ...           ts3.8 (4 years ago)
  • 5.0.21                                ...           ts3.9 (4 years ago)
  • 5.0.21                                ...           ts4.0 (4 years ago)
  • 5.0.21                                ...           ts4.1 (4 years ago)
  • 5.0.21                                ...           ts4.2 (4 years ago)
  • 5.0.21                                ...           ts4.3 (4 years ago)
  • 5.0.21                                ...           ts4.4 (4 years ago)
  • 5.0.21                                ...           ts4.5 (4 years ago)
  • 5.0.21                                ...           ts4.6 (4 years ago)
  • 5.0.21                                ...           ts4.7 (4 years ago)
  • 5.0.21                                ...           ts4.8 (4 years ago)
  • 5.0.21                                ...           ts4.9 (4 years ago)

73 Versions

  • 3.0.12                                ...           4 years ago
  • 4.0.55                                ...           4 years ago
  • 3.0.11                                ...           4 years ago
  • 4.0.54                                ...           4 years ago
  • 5.0.21                                ...           4 years ago
  • 5.0.20                                ...           5 years ago
  • 4.0.53                                ...           5 years ago
  • 5.0.19                                ...           5 years ago
  • 3.0.10                                ...           7 years ago
  • 4.0.52                                ...           7 years ago
  • 5.0.18                                ...           7 years ago
  • 5.0.17                                ...           7 years ago
  • 5.0.16                                ...           8 years ago
  • 5.0.15                                ...           8 years ago
  • 5.0.14                                ...           8 years ago
  • 5.0.13                                ...           8 years ago
  • 5.0.12                                ...           8 years ago
  • 5.0.11                                ...           8 years ago
  • 5.0.10                                ...           8 years ago
  • 4.0.51                                ...           8 years ago
  • 5.0.9                                ...           8 years ago
  • 3.0.9                                ...           8 years ago
  • 5.0.8                                ...           9 years ago
  • 3.0.8                                ...           9 years ago
  • 4.0.50                                ...           9 years ago
  • 5.0.7                                ...           9 years ago
  • 4.0.49                                ...           9 years ago
  • 3.0.7                                ...           9 years ago
  • 5.0.6                                ...           9 years ago
  • 5.0.5                                ...           9 years ago
  • 5.0.4                                ...           9 years ago
  • 5.0.3                                ...           9 years ago
  • 4.0.48                                ...           9 years ago
  • 4.0.47                                ...           9 years ago
  • 5.0.2                                ...           9 years ago
  • 5.0.1                                ...           9 years ago
  • 4.0.46                                ...           9 years ago
  • 4.0.45                                ...           9 years ago
  • 5.0.0                                ...           9 years ago
  • 3.0.6                                ...           9 years ago
  • 4.0.44                                ...           9 years ago
  • 4.0.43                                ...           9 years ago
  • 3.0.5                                ...           9 years ago
  • 4.0.42                                ...           9 years ago
  • 3.0.4                                ...           9 years ago
  • 4.0.41                                ...           9 years ago
  • 3.0.3                                ...           9 years ago
  • 3.0.2                                ...           9 years ago
  • 4.0.40                                ...           9 years ago
  • 3.0.1                                ...           9 years ago
  • 4.0.39                                ...           9 years ago
  • 4.0.38                                ...           9 years ago
  • 4.0.37                                ...           9 years ago
  • 3.0.0                                ...           9 years ago
  • 4.0.36                                ...           9 years ago
  • 4.0.35                                ...           9 years ago
  • 4.0.34                                ...           10 years ago
  • 4.0.33                                ...           10 years ago
  • 4.0.32                                ...           10 years ago
  • 4.0.31                                ...           10 years ago
  • 4.0.30                                ...           10 years ago
  • 4.0.29                                ...           10 years ago
  • 4.0.28                                ...           10 years ago
  • 4.0.27                                ...           10 years ago
  • 4.0.26-alpha                                ...           10 years ago
  • 4.0.24-alpha                                ...           10 years ago
  • 4.0.23-alpha                                ...           10 years ago
  • 4.0.22-alpha                                ...           10 years ago
  • 4.0.21-alpha                                ...           10 years ago
  • 4.0.20-alpha                                ...           10 years ago
  • 4.0.19-alpha                                ...           10 years ago
  • 4.0.14-alpha                                ...           10 years ago
  • 4.0.13-alpha                                ...           10 years ago
Maintainers (1)
Downloads
Today 0
This Week 1
This Month 13
Last Day 1
Last Week 12
Last Month 0
Dependencies (2)
Dev Dependencies (0)
None
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |