{"id":21407431,"url":"https://github.com/palashmon/clone-array-objects","last_synced_at":"2025-07-14T00:33:52.186Z","repository":{"id":57200552,"uuid":"140918143","full_name":"palashmon/clone-array-objects","owner":"palashmon","description":"Tiny module to clone an array of objects","archived":false,"fork":false,"pushed_at":"2024-10-30T22:19:06.000Z","size":83,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-11-12T21:44:12.832Z","etag":null,"topics":["array","array-item","array-of-objects","clone","objects","tests"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/palashmon.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"license","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-14T05:20:05.000Z","updated_at":"2024-10-30T22:19:09.000Z","dependencies_parsed_at":"2024-10-02T23:00:35.623Z","dependency_job_id":"b40a1ccd-cdc2-4da6-9b28-4de64d7792b2","html_url":"https://github.com/palashmon/clone-array-objects","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/palashmon%2Fclone-array-objects","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/palashmon%2Fclone-array-objects/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/palashmon%2Fclone-array-objects/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/palashmon%2Fclone-array-objects/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/palashmon","download_url":"https://codeload.github.com/palashmon/clone-array-objects/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225934431,"owners_count":17547737,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["array","array-item","array-of-objects","clone","objects","tests"],"created_at":"2024-11-22T16:52:18.985Z","updated_at":"2024-11-22T16:52:19.623Z","avatar_url":"https://github.com/palashmon.png","language":"JavaScript","readme":"# clone-array-objects ![CI](https://github.com/palashmon/clone-array-objects/actions/workflows/main.yml/badge.svg)\n\n\u003e Tiny module to clone an array of objects\n\n## Install\n\n```\n$ npm i clone-array-objects\n```\n\n## Usage\n\nThis module helps us to get cloned array of objects\n\n```js\nconst cloneArrayObjects = require('clone-array-objects');\nlet users = [{ id: 1, username: 'bret' }, { id: 2, username: 'samantha' }];\n\n// Clone this users array\nlet clonedUsers = cloneArrayObjects(users);\nconsole.log(clonedUsers);\n//=\u003e [{ id: 1, username: 'bret' }, { id: 2, username: 'samantha' }];\n\n// Let us modify one of the object key value in the actual users array\nusers[1].username = 'ava';\n\n// So, actual users array has been updated now\nconsole.log(users);\n//=\u003e [{ id: 1, username: 'bret' }, { id: 2, username: 'ava' }];\n\n// But, the cloned users array is still the same\nconsole.log(clonedUsers);\n//=\u003e [{ id: 1, username: 'bret' }, { id: 2, username: 'samantha' }];\n```\n\n## API\n\n### cloneArrayObjects(arrayInput)\n\n#### arrayInput\n\nType: `Array`\u003cbr\u003e\nDefault: `[]`\n\nMust be a JavaScript Array. This is main array of object that we will like to clone.\n\n## License\n\nMIT © [Palash Mondal](https://github.com/palashmon)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpalashmon%2Fclone-array-objects","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpalashmon%2Fclone-array-objects","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpalashmon%2Fclone-array-objects/lists"}