JSFiddle - React, Tailwind, and code Playground

by Alexander

JavaScript

console.clear();

const obj = {
	a: 1,
  b: 2,
  c: 3
}

obj[Symbol.iterator] = function* () { return Object.entries(obj) }

const a = [...obj].map(x => x**2);

console.log(a);