How can I access the key values of the objects stored in a predefined array?
const temp = [
{ key: "name", value: "mike" },
{ key: "gender", value: "male" },
];
I am interested in retrieving the key values, such as name and gender, from the objects within the temp array to create a union type.