{"id":18488356,"url":"https://github.com/swordev/merge","last_synced_at":"2026-01-15T22:20:27.211Z","repository":{"id":3211215,"uuid":"4245486","full_name":"swordev/merge","owner":"swordev","description":null,"archived":false,"fork":false,"pushed_at":"2024-02-06T16:25:03.000Z","size":531,"stargazers_count":177,"open_issues_count":11,"forks_count":40,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-11-20T21:25:43.337Z","etag":null,"topics":["clone","extend","javascript","merge","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/swordev.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2012-05-07T01:46:14.000Z","updated_at":"2025-11-11T13:52:13.000Z","dependencies_parsed_at":"2024-06-18T12:24:41.599Z","dependency_job_id":"10fa8ad5-ec49-4b14-8628-74762ce10676","html_url":"https://github.com/swordev/merge","commit_stats":null,"previous_names":["yeikos/js.merge"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/swordev/merge","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swordev%2Fmerge","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swordev%2Fmerge/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swordev%2Fmerge/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swordev%2Fmerge/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/swordev","download_url":"https://codeload.github.com/swordev/merge/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/swordev%2Fmerge/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27448809,"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","status":"online","status_checked_at":"2025-12-02T02:00:06.387Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["clone","extend","javascript","merge","typescript"],"created_at":"2024-11-06T12:51:36.649Z","updated_at":"2026-01-15T22:20:27.191Z","avatar_url":"https://github.com/swordev.png","language":"TypeScript","readme":"# merge\n\n[![workflow-badge]](https://github.com/swordev/merge/actions/workflows/ci.yaml) [![license-badge]](https://github.com/swordev/merge#license)\n\n[workflow-badge]: https://img.shields.io/github/actions/workflow/status/swordev/merge/ci.yaml?branch=main\n[license-badge]: https://img.shields.io/github/license/swordev/merge\n\n\u003e (recursive)? merging of (cloned)? objects.\n\n## Installation\n\n```sh\nnpm install merge\n```\n\n## Usage\n\n### API\n\n```ts\nmerge(clone: boolean, ...items: Object[])\nmerge(...items: Object[])\nmerge.recursive(clone: boolean, ...items: Object[])\nmerge.recursive(...items: Object[])\n```\n\n### Examples\n\n```js\nconst objectA = {};\n\nmerge(objectA, { value: 1 }, { str: \"hello world\" });\n\nconst objectB = merge(true, objectA, { value: 2 });\n\nobjectA; // { value: 1, str: 'hello world' }\nobjectB; // { value: 2, str: 'hello world' }\n```\n\n```js\nconst objectA = {};\n\nmerge.recursive(\n  objectA,\n  { level: { value: 1 } },\n  { level: { str: \"hello world\" } },\n);\nconst objectB = merge.recursive(true, objectA, { level: { value: 2 } });\n\nobjectA.level; // { value: 1, str: 'hello world' }\nobjectB.level; // { value: 2, str: 'hello world' }\n```\n\n## Development\n\n### Requirements\n\n- [Node.js v18](https://nodejs.org)\n- [pnpm v8](https://pnpm.io)\n\n### Build\n\n```sh\npnpm build\n```\n\n### Test\n\n```sh\npnpm test\n```\n\n## License\n\nDistributed under the MIT License. See LICENSE file in each package for more information.\n","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswordev%2Fmerge","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fswordev%2Fmerge","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fswordev%2Fmerge/lists"}