📅  最后修改于: 2022-03-11 15:03:54.748000             🧑  作者: Mango
var myMap = new Map();
myMap.set("0", "foo");
myMap.set(1, "bar");
myMap.set({}, "baz");
for (const [key, value] of Object.entries(myMap)) {
console.log(key, value);
}