Need Package Maintenance

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

    0.7.3 • Public • Published

    Installation

    npm install --save @types/clamp-js

    Summary

    This package contains type definitions for clamp-js (https://github.com/xavi160/Clamp.js).

    Details

    Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/clamp-js.

    index.d.ts

    // Type definitions for clamp-js 0.7
    // Project: https://github.com/xavi160/Clamp.js
    // Definitions by: Sebastiaan de Rooij <https://github.com/Hikariii>
    // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
    
    declare namespace clamp {
        interface ClampOptions {
            clamp?: number|string | undefined;
            useNativeClamp?: boolean | undefined;
            splitOnChars?: string[] | undefined;
            animate?: boolean | undefined;
            truncationChar?: string | undefined;
            truncationHTML?: string | null | undefined;
        }
    
        interface ClampResponse {
            original: string;
            clamped: string;
        }
    }
    
    declare function clamp(element: HTMLElement, options?: clamp.ClampOptions): clamp.ClampResponse;
    
    export = clamp;
    export as namespace clamp;

    Additional Details

    • Last updated: Thu, 08 Jul 2021 09:07:53 GMT
    • Dependencies: none
    • Global values: clamp

    Credits

    These definitions were written by Sebastiaan de Rooij.

    Keywords

    none

    Install

    npm i @types/clamp-js

    DownloadsWeekly Downloads

    2,864

    Version

    0.7.3

    License

    MIT

    Unpacked Size

    4.13 kB

    Total Files

    4

    Last publish

    Collaborators

    • types