@types/color-support
TypeScript icon, indicating that this package has built-in type declarations

1.1.4 • Public • Published

Installation

npm install --save @types/color-support

Summary

This package contains type definitions for color-support (https://github.com/isaacs/color-support#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/color-support.

index.d.ts

/// <reference types="node" />

type ColorSupportLevel = 0 | 1 | 2 | 3;

interface ColorSupportOptions {
    alwaysReturn?: boolean | undefined;
    env?: NodeJS.ProcessEnv | undefined;
    ignoreCI?: boolean | undefined;
    ignoreDumb?: boolean | undefined;
    ignoreTTY?: boolean | undefined;
    level?: ColorSupportLevel | undefined;
    stream?: NodeJS.WriteStream | undefined;
    term?: string | undefined;
}

interface ColorSupportResult {
    level: ColorSupportLevel;
    hasBasic: boolean;
    has256: boolean;
    has16m: boolean;
}

type ColorSupport = (options?: ColorSupportOptions, obj?: ColorSupportResult) => false | ColorSupportResult;

declare var colorSupport: ColorSupport;

export = colorSupport;

Additional Details

  • Last updated: Mon, 06 Nov 2023 22:41:05 GMT
  • Dependencies: @types/node

Credits

These definitions were written by Guketlev Dmitry.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/color-support

Weekly Downloads

12,589

Version

1.1.4

License

MIT

Unpacked Size

4.11 kB

Total Files

5

Last publish

Collaborators

  • types