{"id":20018395,"url":"https://github.com/phpstan/phpstan-beberlei-assert","last_synced_at":"2025-04-07T12:08:37.194Z","repository":{"id":31869863,"uuid":"130029406","full_name":"phpstan/phpstan-beberlei-assert","owner":"phpstan","description":"PHPStan extension for beberlei/assert","archived":false,"fork":false,"pushed_at":"2024-03-29T19:41:23.000Z","size":136,"stargazers_count":36,"open_issues_count":5,"forks_count":14,"subscribers_count":4,"default_branch":"1.1.x","last_synced_at":"2024-04-14T05:41:30.386Z","etag":null,"topics":["assert","php","php7","phpstan","static-analysis","static-code-analysis"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/phpstan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2018-04-18T08:24:56.000Z","updated_at":"2024-03-04T13:16:16.000Z","dependencies_parsed_at":"2023-02-11T05:45:13.884Z","dependency_job_id":"b16d6fe0-86ec-41ae-95a5-199a816b37a0","html_url":"https://github.com/phpstan/phpstan-beberlei-assert","commit_stats":{"total_commits":117,"total_committers":16,"mean_commits":7.3125,"dds":"0.46153846153846156","last_synced_commit":"b335d5eb908323177d4f88756b46a40f14b57ebc"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phpstan%2Fphpstan-beberlei-assert","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phpstan%2Fphpstan-beberlei-assert/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phpstan%2Fphpstan-beberlei-assert/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phpstan%2Fphpstan-beberlei-assert/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/phpstan","download_url":"https://codeload.github.com/phpstan/phpstan-beberlei-assert/tar.gz/refs/heads/1.1.x","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247284944,"owners_count":20913704,"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":["assert","php","php7","phpstan","static-analysis","static-code-analysis"],"created_at":"2024-11-13T08:22:05.141Z","updated_at":"2025-04-07T12:08:37.166Z","avatar_url":"https://github.com/phpstan.png","language":"PHP","readme":"# PHPStan beberlei/assert extension\n\n[![Build](https://github.com/phpstan/phpstan-beberlei-assert/workflows/Build/badge.svg)](https://github.com/phpstan/phpstan-beberlei-assert/actions)\n[![Latest Stable Version](https://poser.pugx.org/phpstan/phpstan-beberlei-assert/v/stable)](https://packagist.org/packages/phpstan/phpstan-beberlei-assert)\n[![License](https://poser.pugx.org/phpstan/phpstan-beberlei-assert/license)](https://packagist.org/packages/phpstan/phpstan-beberlei-assert)\n\n* [PHPStan](https://phpstan.org/)\n* [beberlei/assert](https://github.com/beberlei/assert)\n\n## Description\n\nThe main scope of this extension is to help PHPStan to detect the type of object after the `Assert\\Assertion` validation.\n\n```php\n\u003c?php declare(strict_types = 1);\nuse Assert\\Assertion;\n\nfunction demo(?int $a) {\n\t// ...\n\n\tAssertion::integer($a);\n\t// PHPStan is now aware that $a can no longer be `null` at this point\n\n\treturn ($a === 10);\n}\n```\n\n## Installation\n\nTo use this extension, require it in [Composer](https://getcomposer.org/):\n\n```\ncomposer require --dev phpstan/phpstan-beberlei-assert\n```\n\nIf you also install [phpstan/extension-installer](https://github.com/phpstan/extension-installer) then you're all set!\n\n\u003cdetails\u003e\n  \u003csummary\u003eManual installation\u003c/summary\u003e\n\nIf you don't want to use `phpstan/extension-installer`, include extension.neon in your project's PHPStan config:\n\n```\nincludes:\n    - vendor/phpstan/phpstan-beberlei-assert/extension.neon\n```\n\u003c/details\u003e\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphpstan%2Fphpstan-beberlei-assert","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphpstan%2Fphpstan-beberlei-assert","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphpstan%2Fphpstan-beberlei-assert/lists"}