3.0.13 • Published 3 months ago

@types/redux-logger v3.0.13

Weekly downloads
215,502
License
MIT
Repository
github
Last release
3 months ago

Installation

npm install --save @types/redux-logger

Summary

This package contains type definitions for redux-logger (https://github.com/theaqua/redux-logger).

Details

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

index.d.ts

// Type definitions for redux-logger 3.0
// Project: https://github.com/theaqua/redux-logger
// Definitions by: Alexander Rusakov <https://github.com/arusakov>
//                 Kevin Groat <https://github.com/kgroat>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

export as namespace ReduxLogger;

import * as Redux from 'redux';

export const logger: Redux.Middleware;

export type LoggerPredicate = (
    getState: () => any,
    action: any,
    logEntry?: LogEntryObject
) => boolean;

export type StateToString = (state: any) => string;
export type ActionToString = (action: any) => string;
export type ErrorToString = (error: any, prevState: any) => string;

export interface ColorsObject {
    title?: boolean | ActionToString | undefined;
    prevState?: boolean | StateToString | undefined;
    action?: boolean | ActionToString | undefined;
    nextState?: boolean | StateToString | undefined;
    error?: boolean | ErrorToString | undefined;
}

export interface LevelObject {
    prevState?: string | boolean | StateToString | undefined;
    action?: string | boolean | ActionToString | undefined;
    nextState?: string | boolean | StateToString | undefined;
    error?: string | boolean | ErrorToString | undefined;
}

export interface LogEntryObject {
    action?: string | boolean | ActionToString | undefined;
    started?: number | undefined;
    startedTime?: Date | undefined;
    took?: number | undefined;
    error?(error: any): any;
    nextState?(state: any): any;
    prevState?(state: any): any;
}

export interface ReduxLoggerOptions {
    level?: string | ActionToString | LevelObject | undefined;
    duration?: boolean | undefined;
    timestamp?: boolean | undefined;
    colors?: ColorsObject | false | undefined;
    titleFormatter?(formattedAction: any, formattedTime: string, took: number): string;
    logger?: any;
    logErrors?: boolean | undefined;
    collapsed?: boolean | LoggerPredicate | undefined;
    predicate?: LoggerPredicate | undefined;
    diff?: boolean | undefined;
    diffPredicate?: LoggerPredicate | undefined;
    stateTransformer?(state: any): any;
    actionTransformer?(action: any): any;
    errorTransformer?(error: any): any;
}

export function createLogger(options?: ReduxLoggerOptions): Redux.Middleware;

export default logger;

Additional Details

  • Last updated: Wed, 07 Jul 2021 18:31:54 GMT
  • Dependencies: @types/redux
  • Global values: ReduxLogger

Credits

These definitions were written by Alexander Rusakov, and Kevin Groat.

@modern-js/runtime@commercetools-frontend/application-shell@aukindustries/auk-componentsdt-ai-workshoogo-niuyapingplatinion-paris-react-componentscra-template-notum-material-uisuppliers_extendeal_npm_testelectron-weatly-managecomm-sidepanel-micro-fe-testlib-task-modsenlib-task-toastlibtoastlibtoast-testlibtoasttest-modtoast-lib-task-modsenreact-vrw@everything-registry/sub-chunk-955@thepowereco/hub@hackforplay/ide@infinitebrahmanuniverse/nolb-_types_refawkes-client-browserdream-redux@fishx/dva@frederic.enard/react-component-rollup-typescript-boilerplate@frederic.enard/react-redux-connectoreasy-use-reduxehr-cms-ui@fay-react/react-redux-loadablesfd-react_ts_demoselfcare-common-frontendsmart-salon-pos-system@keystore/libstudiokit-scaffolding-jssuppliers_extendeal_npm_test_angel@plenty-ag/styleguides-typescriptuseloggedreducerunified-redux@r3m0t/vscode-jupyterjustinlivi.com@reactgo/clijs-demo-utils@rontrol/bootstrap@robtucker/redux-store@sables/frameworksolar-solution-js-sdk@mhy/mhy@magomed/create-trinity-apptelemdnow-patient-frontend-v2@mpfe/mpa@modern-js/plugin-state@mocoding/react-app-router-redux@plurall-boss/components@pagopa/selfcare-common-frontend@noordinarysites/no-formhoogohoogo-wangziyao-haha@nemo.travel/results-widget@nemo.travel/search-widgethbattendees@latviancoder/react-scripts@memo28/enhance-redux@monsterkrampe/react-scriptsts-react-npm@openchemistry/jupyterlabhutchestmhyd@yourwishes/app-store@storefront/flux-capacitormixology@zalastax/nolb-_types_reapani-dukaan-redux-factoryws-image-manager@ti-fe/sitelib-toast-task-modsen@szero/pc-reduxmahedev-shared@zqbflynn/kernelmod-test-libtoastmod-test-toastmod-toasttestmodsen-test-toastmod-libtoastmod-libtoasttest@activity-maker/component-devtoolsaugury-extension@axa-ch/pod-eclaimskpv-claimsinfocardano-wallet-connectedcarmine-ilhedge-widget@carmel/react-stack@cagolini/cag-react-scriptspittbosspluscore@clickopolis/app@codebuild-hu/cookie-jarproject_basic_framework@coral-cloud/sitecosmouiflexclean-arch-core@blocksx/design
3.0.13

3 months ago

3.0.12

5 months ago

3.0.10

7 months ago

3.0.11

6 months ago

3.0.9

3 years ago

3.0.8

4 years ago

3.0.7

5 years ago

3.0.6

6 years ago

3.0.5

7 years ago

3.0.4

7 years ago

3.0.3

7 years ago

3.0.2

7 years ago

3.0.1

7 years ago

3.0.0

7 years ago

2.10.0

7 years ago

2.6.34

7 years ago

2.6.33

7 years ago

2.6.32

8 years ago

2.6.31

8 years ago

2.6.30

8 years ago

2.6.29

8 years ago

2.6.28

8 years ago

2.6.27-alpha

8 years ago

2.6.25-alpha

8 years ago

2.6.24-alpha

8 years ago

2.6.23-alpha

8 years ago

2.6.22-alpha

8 years ago

2.6.21-alpha

8 years ago

2.6.20-alpha

8 years ago

2.6.15-alpha

8 years ago

2.6.14-alpha

8 years ago