Have ideas to improve npm?Join in the discussion! »

    lists-is

    0.1.3 • Public • Published

    lists-is

    NOTE: lists-is was renamed to @extra-lists/is. NPM

    Check if value is lists.

    const is = require('lists-is');
    // is(<value>)
     
    = ['italy', 'rome', 'caesar'];
    is([a.keys(), a]);
    // true
    = {p1: 'pompeii', p2: 'caesar', p2: 'crassus'};
    is([Object.keys(a), Object.values(a)]);
    // true
    = new Set(['caesar', 'calphurnia']);
    is([a.keys(), a.values()]);
    // true
    = new Map([['h', 'brutus'], ['w', 'portia']]);
    is([a.keys(), a.values()]);
    // true
    is('cassius');
    // false

    Keywords

    Install

    npm i lists-is

    DownloadsWeekly Downloads

    2

    Version

    0.1.3

    License

    MIT

    Unpacked Size

    1.44 kB

    Total Files

    3

    Last publish

    Collaborators

    • avatar