DEV Community

Cover image for How to Access Object's Keys, Values, and Entries in JavaScript
Dezina
Dezina

Posted on

How to Access Object's Keys, Values, and Entries in JavaScript

      <div>

       {
          Object.entries(slot).map(([key, value]) =>
          <div>
            {console.log("key", key)}
            <span>{key}</span>
            <div>

            {value.map(g => (
              <div>{console.log("g", g.eTime)}
              <span>{g.eTime}</span>
              </div>
            ))}
            </div>
          </div>
        )
       }
     </div>
Enter fullscreen mode Exit fullscreen mode

Top comments (0)