Skip to content

Commit 71a178d

Browse files
committed
Added the comment why es6-map is needed.
1 parent 04813da commit 71a178d

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

lib/store.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,16 @@ var defaultStoreOptions = {
1111
clean: true
1212
}
1313

14+
/**
15+
* es6-map can preserve insertion order even if ES version is older.
16+
*
17+
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map#Description
18+
* It should be noted that a Map which is a map of an object, especially
19+
* a dictionary of dictionaries, will only map to the object's insertion
20+
* order. In ES2015 this is ordered for objects but for older versions of
21+
* ES, this may be random and not ordered.
22+
*
23+
*/
1424
var Map = require('es6-map')
1525

1626
/**

0 commit comments

Comments
 (0)