I have this code
console.log({Stats:Object.fromEntries(['score','count','w','l','d'].map(s=>[s,teamsToPlay[0][s]]))})
//Stats: { score:123 count:22 w:12 l:10 d:0 }
How can I extract value/number of each entry?
I tried
const d = ({Stats:Object.fromEntries(['d'].map(s=>[s,teamsToPlay[0][s]]))}).match(/\d+/);
but it gives
{(intermediate value)}.match is not a function