MCPcopy Create free account
hub / github.com/node-modules/utility / map1

Function map1

benchmark/map.cjs:19–29  ·  view source on GitHub ↗
(obj)

Source from the content-addressed store, hash-verified

17}
18
19function map1(obj) {
20 const map = Object.create(null);
21 if (!obj) {
22 return map;
23 }
24
25 for (const key in obj) {
26 map[key] = obj[key];
27 }
28 return map;
29}
30
31function map2(obj) {
32 const map = new Map();

Callers 1

map.cjsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…