Created
February 17, 2020 17:20
-
-
Save BrunoGiubilei/15419f01332e18ac28faef4cba992e43 to your computer and use it in GitHub Desktop.
copy prototype for array of object
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Array.prototype.copy = function() { | |
return this.map(function(e){return {...e}}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment