{"id":91687,"library":"tomasvotruba-cognitive-complexity","title":"Cognitive Complexity","description":"PHPStan rules to measure cognitive complexity of your classes and methods","status":"active","version":"1.0.0","language":"php","source_language":null,"source_url":"https://github.com/TomasVotruba/cognitive-complexity","tags":["phpstan","cognitive-complexity","code-quality","static-analysis"],"install":[{"cmd":"composer require tomasvotruba/cognitive-complexity","lang":"bash","label":"composer require"}],"dependencies":[],"imports":[{"symbol":"CognitiveComplexityRule","correct":"use TomasVotruba\\CognitiveComplexity\\Rules\\CognitiveComplexityRule;"}],"quickstart":{"code":"use TomasVotruba\\CognitiveComplexity\\Rules\\CognitiveComplexityRule;\n\n// Register rule in PHPStan config","lang":"php","description":"Register the cognitive complexity rule in PHPStan"},"warnings":[{"fix":"Install phpstan/phpstan and add the rule to your phpstan.neon","message":"Requires PHPStan to be installed and configured","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"search_vec":"'analysi':23 'class':11 'code':19 'code-qu':18 'cognit':1,7,16 'cognitive-complex':15 'complex':2,8,17 'measur':6 'method':13 'phpstan':3,14 'qualiti':20 'rule':4 'static':22 'static-analysi':21","created_at":"2026-06-19T09:21:21.666889+00:00","updated_at":"2026-06-19T09:21:21.666889+00:00","problems":[],"ecosystem":"packagist","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/TomasVotruba/cognitive-complexity","github":"https://github.com/TomasVotruba/cognitive-complexity","docs":null,"changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["testing"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-19","next_check":"2026-12-16","install_tag":null}}