CodesJava

Easy learning with example program codes

Map entries() method JavaScript

The JavaScript map entries() method is used to retrieve an object of Map iterator that contains the key-value pair for each element.

Note: The iterator object keeps the insertion order of map elements.

Syntax:

mapObj.entries()

Return:
An object of Map iterator

Example:

<!DOCTYPE html>
<html>
<body>
<script>  
var bday=new Date("November 16, 1994 21:10:10");  
document.writeln(bday.toDateString());  
</script>  
</body>
</html>

Output:

Wed Nov 16 1994
Please follow and like us:
error








Copyright © 2019 CodesJava DMCA.com Protection Status