@types/react-css-modules
TypeScript icon, indicating that this package has built-in type declarations

4.6.8 • Public • Published

Installation

npm install --save @types/react-css-modules

Summary

This package contains type definitions for react-css-modules (https://github.com/gajus/react-css-modules).

Details

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

index.d.ts

interface TypeOptions {
    allowMultiple?: boolean | undefined;
    handleNotFoundStyleName?: "throw" | "log" | "ignore" | undefined;
}

type StylesObject = any;

interface CSSModules {
    (defaultStyles: StylesObject, options?: TypeOptions): <C extends Function>(Component: C) => C;
    <C extends Function>(Component: C, defaultStyles: StylesObject, options?: TypeOptions): C;
}

declare namespace CSSModules {
    // Extend your component's Prop interface with this one to get access to `this.props.styles`
    //
    // interface MyComponentProps extends CSSModules.InjectedCSSModuleProps {}
    interface InjectedCSSModuleProps {
        styles?: StylesObject | undefined;
    }
}

declare let CSSModules: CSSModules;

export = CSSModules;

declare module "react" {
    interface Attributes {
        styleName?: string | undefined;
    }
    interface HTMLAttributes<T> {
        styleName?: string | undefined;
    }
    interface SVGAttributes<T> {
        styleName?: string | undefined;
    }
}

Additional Details

  • Last updated: Tue, 07 Nov 2023 09:09:39 GMT
  • Dependencies: none

Credits

These definitions were written by Kostya Esmukov, and Tadas Dailyda.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
4.6.87,105ts5.8
4.6.87,105ts5.7
4.6.87,105latest
4.6.87,105ts4.5
4.6.87,105ts4.6
4.6.87,105ts4.7
4.6.87,105ts4.8
4.6.87,105ts4.9
4.6.87,105ts5.0
4.6.87,105ts5.1
4.6.87,105ts5.2
4.6.87,105ts5.3
4.6.87,105ts5.4
4.6.87,105ts5.5
4.6.87,105ts5.6
4.6.87,105ts5.9
4.6.43,001ts3.6
4.6.43,001ts3.7
4.6.43,001ts3.8
4.6.43,001ts3.9
4.6.43,001ts4.0
4.6.43,001ts4.1
4.6.43,001ts4.2
4.6.21,349ts2.8
4.6.21,349ts2.9
4.6.21,349ts3.0
4.6.21,349ts3.1
4.6.21,349ts3.2
4.6.21,349ts3.3
4.6.21,349ts3.4
4.6.3349ts3.5
4.2.0228ts2.1
4.2.0228ts2.2
4.6.53ts4.3
4.6.53ts4.4
4.6.01ts2.3
4.6.01ts2.4
4.6.01ts2.5
3.7.51ts2.0
4.6.10ts2.6
4.6.10ts2.7

Version History

VersionDownloads (Last 7 Days)Published
4.6.87,105
4.6.758
4.6.679
4.6.53
4.6.43,001
4.6.3349
4.6.21,349
4.6.10
4.6.01
4.2.10
4.2.0228
3.7.60
3.7.51
3.7.40
3.7.30
3.7.20
3.7.10

Package Sidebar

Install

npm i @types/react-css-modules

Weekly Downloads

12,174

Version

4.6.8

License

MIT

Unpacked Size

4.84 kB

Total Files

5

Last publish

Collaborators

  • types