There are multiple ways to iterate an object in javascript. But I personally recommend the following solution.

Syntax:

Object.entries( myObject ).forEach( ( entry ) => {
    let key = entry[ 0 ];
    let value = entry[ 1 ];
    console.log( key, value );
} );