JSPM

@yjl9903/setmap

1.0.5
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 9
  • Score
    100M100P100Q62862F
  • License MIT

Package Exports

  • @yjl9903/setmap

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@yjl9903/setmap) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

SetMap

Node.js CI

Use Hash to check whether two sets are equal.

Install

yarn add @yjl9903/setmap

Usage

const a = { a: 1 };
const b = { b: 2 };
const c = { c: 3 };

const set = new SetSet<object>([a]);

set.has([a]); // true
set.has([b]); // false

set.add([a, b, c]); // true

set.has([a, c, b]); // true
set.has([b, a, c]); // true
set.has([b, c, a]); // true
set.has([c, a, b]); // true
set.has([c, b, a]); // true

set.has([a, b]); // false
set.has([a, c]); // false
set.has([b, c]); // false

License

MIT