advanced-map-altered-equal
TypeScript icon, indicating that this package has built-in type declarations

0.0.5 • Public • Published

advanced-map-altered-equal

Map-like class with customizable equality operator

Usage

import AlteredEqual from 'advanced-map-altered-equal'
const map = new AlteredEqual(Map, (a, b) => String(a) === String(b))
map.set(0, 'zero')
map.get('0') // expect: 'zero'
map.get({ toString: () => '0' }) // expect: 'zero'

License

MIT © Hoàng Văn Khải

Readme

Keywords

Package Sidebar

Install

npm i advanced-map-altered-equal

Weekly Downloads

8

Version

0.0.5

License

MIT

Unpacked Size

3.8 kB

Total Files

4

Last publish

Collaborators

  • khai96_