JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 3
  • Score
    100M100P100Q31224F
  • License ISC

Package Exports

  • strong-map

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 (strong-map) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Strong Map

License Build Status Coverage Status Github Issues Version Node Version Last Commit

NPM

This library is made to extend the functionality of Javascript's Map to solve common problems.

What more?

Improved get function

If you usually use the Map objeasdct in your life and you have used objects like keys, sure that you are been frustrated with the .get method because you only can get a value if the key is THE SAME object, referenced. With this library this doesn't happen, for example:

const StrongMap = require('../lib');

// With Vanilla Map
const map = new Map([
  ['Javascript', 'Good'],
  [{ lang: 'PHP' }, 'Bad']
]);

let js = map.get('Javascript');
let php = map.get({ lang: 'PHP' });
console.log(js); // Good
console.log(php); // undefined

// With StrongMap
const strongMap = new StrongMap([
  ['Javascript', 'Good'],
  [{ lang: 'PHP' }, 'Bad']
]);

js = strongMap.get('Javascript');
php = strongMap.get({ lang: 'PHP' });
console.log(js); // Good
console.log(php); // Bad

Maintainers