Nightmare Prom Memories

    condense-whitespace
    TypeScript icon, indicating that this package has built-in type declarations

    3.0.0 • Public • Published

    condense-whitespace

    Remove leading, trailing, and repeated whitespace from a string

    Install

    $ npm install condense-whitespace
    

    Usage

    import condenseWhitespace from 'condense-whitespace';
    
    condenseWhitespace('  foo bar     baz ');
    //=> 'foo bar baz'

    Related

    • trim-repeated - Trim a consecutively repeated substring: foo--bar---bazfoo-bar-baz

    Install

    npm i condense-whitespace

    DownloadsWeekly Downloads

    34,941

    Version

    3.0.0

    License

    MIT

    Unpacked Size

    2.85 kB

    Total Files

    5

    Last publish

    Collaborators

    • sindresorhus