Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js convert obj to array

const array = [
  ['key', 1],
  ['two', 2],
];

Object.fromEntries(array);
// { one: 1, two: 2 }
Source by www.samanthaming.com #
 
PREVIOUS NEXT
Tagged: #js #convert #obj #array
ADD COMMENT
Topic
Name
7+2 =