{"id":15525379,"url":"https://github.com/ghostwriter/collection","last_synced_at":"2026-04-06T03:01:56.067Z","repository":{"id":38029475,"uuid":"506107965","full_name":"ghostwriter/collection","owner":"ghostwriter","description":"Provides a Collection implementation for PHP","archived":false,"fork":false,"pushed_at":"2025-04-22T00:45:01.000Z","size":688,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"2.0.x","last_synced_at":"2025-04-22T01:29:19.305Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ghostwriter.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["ghostwriter"]}},"created_at":"2022-06-22T05:22:25.000Z","updated_at":"2025-04-22T00:45:04.000Z","dependencies_parsed_at":"2024-04-28T13:27:47.352Z","dependency_job_id":"b437b8cf-c1f5-4f67-8c7c-5c46948316da","html_url":"https://github.com/ghostwriter/collection","commit_stats":{"total_commits":111,"total_committers":1,"mean_commits":111.0,"dds":0.0,"last_synced_commit":"d90268386a32a562c29a8b152d38d5e36690c2ff"},"previous_names":[],"tags_count":17,"template":false,"template_full_name":"ghostwriter/wip","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostwriter%2Fcollection","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostwriter%2Fcollection/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostwriter%2Fcollection/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ghostwriter%2Fcollection/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ghostwriter","download_url":"https://codeload.github.com/ghostwriter/collection/tar.gz/refs/heads/2.0.x","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250162516,"owners_count":21385112,"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":[],"created_at":"2024-10-02T10:57:11.414Z","updated_at":"2025-10-25T16:19:05.508Z","avatar_url":"https://github.com/ghostwriter.png","language":"PHP","funding_links":["https://github.com/sponsors/ghostwriter"],"categories":[],"sub_categories":[],"readme":"# Collection\n\n[![GitHub Sponsors](https://img.shields.io/github/sponsors/ghostwriter?label=Sponsor+@ghostwriter/collection\u0026logo=GitHub+Sponsors)](https://github.com/sponsors/ghostwriter)\n[![Automation](https://github.com/ghostwriter/collection/actions/workflows/automation.yml/badge.svg)](https://github.com/ghostwriter/collection/actions/workflows/automation.yml)\n[![Supported PHP Version](https://badgen.net/packagist/php/ghostwriter/collection?color=8892bf)](https://www.php.net/supported-versions)\n[![Downloads](https://badgen.net/packagist/dt/ghostwriter/collection?color=blue)](https://packagist.org/packages/ghostwriter/collection)\n\nProvides a Collection implementation for PHP.\n\n## Installation\n\nYou can install the package via composer:\n\n``` bash\ncomposer require ghostwriter/collection\n```\n\n### Star ⭐️ this repo if you find it useful\n\nYou can also star (🌟) this repo to find it easier later.\n\n## Usage\n\n```php\n/** @var \\Ghostwriter\\Collection\\Collection $collection */\n$collection = Collection::new([1, 2, 3])\n    -\u003eappend([4, 5, 6, 7, 8, 9])\n    -\u003emap(static fn ($v): int =\u003e $v * 10)\n    -\u003efilter(static fn ($v): bool =\u003e 0 === $v % 20);\n    \n$collection-\u003etoArray();  // [20, 40, 60, 80]\n$collection-\u003edrop(1)     // [40, 60, 80]\n           -\u003etake(2)     // [40, 60]\n           -\u003eslice(1, 1) // [60]\n           -\u003etoArray();  // [60]\n```\n\n### Credits\n\n- [Nathanael Esayeas](https://github.com/ghostwriter)\n- [All Contributors](https://github.com/ghostwriter/collection/contributors)\n\n## Thank you\n\nThank you for freely sharing your knowledge, insight and free time with me. I am grateful for your help and support.\n\n- [Larry Garfield](https://github.com/crell)\n- [Aleksei Khudiakov](https://github.com/xerkus)\n- [Andi Rückauer](https://github.com/arueckauer)\n\n\n### Changelog\n\nPlease see [CHANGELOG.md](./CHANGELOG.md) for more information on what has changed recently.\n\n### License\n\nPlease see [LICENSE](./LICENSE) for more information on the license that applies to this project.\n\n### Security\n\nPlease see [SECURITY.md](./SECURITY.md) for more information on security disclosure process.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghostwriter%2Fcollection","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fghostwriter%2Fcollection","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fghostwriter%2Fcollection/lists"}