Novices Performing Miracles

    just-omit
    TypeScript icon, indicating that this package has built-in type declarations

    2.0.1 • Public • Published

    just-omit

    Part of a library of zero-dependency npm modules that do just do one thing. Guilt-free utilities for every occasion.

    🍦 Try it

    npm install just-omit
    yarn add just-omit

    Copy an object but omit the specified keys

    import omit from 'just-omit';
    
    var obj = {a: 3, b: 5, c: 9};
    omit(obj, ['a', 'c']); // {b: 5}
    omit(obj, 'a', 'c'); // {b: 5}
    omit(obj, ['a', 'b', 'd']); // {c: 9}
    omit(obj, ['a', 'a']); // {b: 5, c: 9}

    Install

    npm i just-omit

    DownloadsWeekly Downloads

    10,385

    Version

    2.0.1

    License

    MIT

    Unpacked Size

    4.54 kB

    Total Files

    8

    Last publish

    Collaborators

    • angus-c