@types/redux-socket.io
TypeScript icon, indicating that this package has built-in type declarations

1.4.6 • Public • Published

Installation

npm install --save @types/redux-socket.io

Summary

This package contains type definitions for redux-socket.io (https://github.com/itaylor/redux-socket.io#readme).

Details

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

index.d.ts

/// <reference types="socket.io-client" />

import { Action, Dispatch, Middleware } from "redux";

export interface MiddlewareOptions {
    eventName?: string | undefined;
    execute?:
        | (<S>(action: Action, emitBound: SocketIOClient.Socket, next: Dispatch<S>, dispatch: Dispatch<S>) => any)
        | undefined;
}

export default function createSocketIoMiddleware(
    socket: SocketIOClient.Socket,
    criteria: string | readonly string[] | ((type: string, action: Action) => boolean),
    options?: MiddlewareOptions,
): Middleware;

Additional Details

Credits

These definitions were written by Igor Voropaev.

/@types/redux-socket.io/

    Package Sidebar

    Install

    npm i @types/redux-socket.io

    Weekly Downloads

    208

    Version

    1.4.6

    License

    MIT

    Unpacked Size

    3.88 kB

    Total Files

    5

    Last publish

    Collaborators

    • types