Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Lightweight dictionaries for ES6
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
COPYING
README.md
dict.js

README.md

dict.js

by Dave herman

Simple dictionaries with lightweight syntax, using ES6 features (proxies, weak maps).

Examples:

js> var d = new Dict({ foo: 17, bar: "hello world", baz: 42 });
js> Dict.size(d)
3
js> d.foo
17
js> "bar" in d
true
js> "hasOwnProperty" in d
false
js> d.hasOwnProperty = "yo dawg"
"yo dawg"
js> Dict.size(d)
4
js> delete d.baz
true
js> "baz" in d
false
js> d instanceof Dict
true
js> d instanceof Object
false
Something went wrong with that request. Please try again.