Skip to content
CAI
Software that uses CAICheck a score

barryvdh/laravel-ide-helper

55.7

Adequate · 13 November 2026

5k

lines of production code

PHP

primary language

6

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

Features

Initial release of PHP templates for IDE integration

This change introduces a new set of PHP scripts in the php-templates directory designed to provide metadata for IDE tooling (specifically VS Code). These scripts scan the Laravel application to generate structured data for routes, middleware, configuration values, translations, views, and authorization policies, enabling features like go-to-definition and autocompletion. The package also includes MIT licensing and documentation noting its basis on the official Laravel VS Code extension.

php-templates · high confidence

Initial release of configurable IDE helper settings

Introduces a new \config/ide-helper.php\ file that allows users to customize the behavior of the IDE helper package. Key configuration options include setting custom filenames for the generated helper and models files, enabling or disabling the generation of fluent helpers, query methods, magic methods, and external builder methods, and controlling whether relation count/exists properties are written to model DocBlocks. Users can also specify model locations, ignore specific models, define model hooks for custom information, and configure extra classes and magic methods for IDE auto-completion support.

config · high confidence

New IDE helper and meta view templates for enhanced autocomplete

The package now ships with new \resources/views/helper.php\ and \resources/views/meta.php\ templates to improve IDE autocomplete. The helper view generates PHP classes for aliases, extended classes, and real-time facades, while also conditionally including a \Fluent\ class definition for migration helpers when the \include\_fluent\ config option is enabled. The meta view generates PhpStorm-specific metadata using the \override\ and \registerArgumentsSet\ functions to provide type hints for container bindings, config values, and specific method arguments, including support for testing mocks.

resources · high confidence

New console commands for Eloquent mixin and IDE generation

The \src/Console\ directory now includes \EloquentCommand\, \GeneratorCommand\, and \MetaCommand\ alongside the existing \ModelsCommand\. \EloquentCommand\ (ide-helper:eloquent) adds the \\Eloquent helper to the base Eloquent model. \GeneratorCommand\ (ide-helper:generate) produces the main IDE helper file, supporting options to include helper files, use an in-memory SQLite driver, generate only Eloquent methods, and optionally write Eloquent model mixins. \MetaCommand\ (ide-helper:meta) generates PhpStorm metadata files containing container bindings, configuration values, and expected arguments.

src/Console · high confidence

Removals

Removal of IDE helper configuration file

The configuration file for the IDE helper functionality (\src/config/config.php\) and its placeholder file (\.gitkeep\) have been removed from the project. This means the default settings for generating IDE helper files, such as the output filename and class alias mappings for Laravel facades, are no longer managed via this configuration file.

src/config · high confidence

Removal of legacy IDE Helper generator command

The \src/Barryvdh/IdeHelper/GeneratorCommand.php\ file, which previously provided the \ide-helper:generate\ console command for creating IDE helper files, has been removed. This eliminates the legacy functionality that generated static method stubs for Laravel aliases to support IDE autocompletion.

src/Barryvdh · high confidence

Behavioural changes

Refactored to PSR-4 namespace and added post-migration model helper generation

The library has been restructured to use the \Barryvdh\\LaravelIdeHelper\ namespace (PSR-4), moving the service provider to \src/IdeHelperServiceProvider.php\. A new \Eloquent\ helper generation command and listener have been added, allowing the IDE helper to automatically regenerate Eloquent model docblocks after database migrations via the \post\_migrate\ configuration option.

src · high confidence

Standardize code style with php-cs-fixer and unify repository configuration

The project replaces its previous coding standards tooling with php-cs-fixer, introducing \.editorconfig\ for consistent editor settings and \.php-cs-fixer.dist.php\/\.php-cs-fixer.tests.php\ for enforcing PSR-12 and custom style rules. Repository hygiene is improved by adding \.gitattributes\ to exclude development artifacts (tests, CI, config) from exports, updating \.gitignore\ to track cache files, and migrating the test runner to PHPUnit 10.5 via \phpunit.xml.dist\. Documentation is consolidated into a new \README.md\ (replacing the old \readme.md\), and the generated \\_IDE\_helper.php\ file is removed from the repository.

(repo-wide) · high confidence

Test coverage

1 commit adding/updating tests in tests; Added base test class for ModelsCommand tests; Added regression tests for PHP 8 attributes before class declarations; Added snapshot test for Eloquent Model interface generation; Added snapshot test for FQCN generation in external Eloquent builder files; Added snapshot test for Laravel custom casts command; Added snapshot test for SoftDeletes model generation; Added snapshot tests for CustomDate and Ignored model commands; Added snapshot tests for Eloquent model getter type inference; Added snapshot tests for ModelsCommand reset behaviors; Added snapshot tests for PHPStorm inspection handling; Added snapshot tests for dynamic relationship model generation; Added snapshot tests for union type handling in ModelsCommand; Added snapshot-based test for ModelsCommand getter functionality; Added test coverage for aliases, macros, DNF types, and real-time facades; Added test coverage for generating PHPDoc on final Eloquent models; Added test coverage for glob pattern support in model directory scanning; Added test fixture for Laravel 11 Authenticatable interface; Added test fixture for attribute getter type inference; Added test fixture for reset and smart-reset options; Added test fixtures for MagicWhere and RelationCountProperties; Added test fixtures for ModelsCommand migration scenarios; Added test fixtures for ModelsCommand scenarios; Added test fixtures for advanced collection casting; Added test fixtures for custom relation types; Added test fixtures for ignored model filtering; Added test for FQN generation in external files; Added test for ModelsCommand interface handling; Added test for SoftDeletes command; Added test for camelCase property generation in phpDoc blocks; Added test for custom PHPDoc tag preservation; Added test helper trait for custom relation types; Added test model for Laravel custom cast scenarios; Added test model for advanced Eloquent casts; Added test models for Eloquent relation variations; Added test models for mixin generation; Added tests for Eloquent Attribute handling in ModelsCommand; Added tests for Eloquent model cast type inference; Added tests for Eloquent query scope detection; Added tests for GeneratorCommand behavior and configuration; Added tests for Laravel custom cast type detection; Added tests for MagicWhere and RelationCountProperties command configurations; Added tests for Model Hooks; Added tests for Model Hooks functionality; Added tests for ModelsCommand basic and custom date scenarios; Added tests for ModelsCommand comment parsing and generics syntax configuration; Added tests for MorphTo intersection type handling; Added tests for MorphTo relationship phpDoc generation; Added tests for PHP 8 union types in ModelsCommand; Added tests for PHPStan imported type handling; Added tests for PHPStorm noinspection tag generation; Added tests for array cast comments in ModelsCommand; Added tests for custom collection support and FQN phpDoc generation; Added tests for custom relation types and nullable relationship enforcement; Added tests for disabling model query methods generation; Added tests for dynamic relationship resolution in ModelsCommand; Added tests for enum default arguments in PHPDoc generation; Added tests for external Eloquent builder PHPDoc generation; Added tests for factory name resolution and PHPDoc generation; Added tests for forced FQN phpDoc generation; Added tests for pivot model generation with custom pivot classes and accessors; Added tests for soft-deleted relationship phpDoc generation; Added tests for the --write-eloquent-helper command option; Added tests for the --write-mixin command output; Added tests for the Eloquent command; Added tests for the MetaCommand; Added tests for the ModelsCommand reset behavior; Added tests for the ignored\_models configuration option; Added tests for typed scope parameters in ModelsCommand; Added tests for variadic parameter support in the Models command; Snapshot test added for ModelsCommand relation count properties; Snapshot test for MagicWhere model generation; Snapshot tests added for Laravel custom cast type resolution; Snapshot tests for PHPDoc generation with FQCNs and new column types; Snapshot tests for advanced Eloquent cast types; Snapshot tests for basic PHPDoc generation; Updated snapshot tests for Eloquent relation nullability and composite keys.

Dependencies

Upgrade to Laravel 11-13 and PHP 8.2 with modernized tooling

The package now requires PHP 8.2 and supports Laravel 11.15, 12, and 13, dropping compatibility with older versions. It replaces the previous docblock library with \barryvdh/reflection-docblock\ and uses \composer/class-map-generator\ for autoloading, while switching static analysis from Psalm to Larastan and adopting PHPUnit snapshot assertions for testing.

(dependencies) · high confidence

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 56 → 56 (-0.5)
  • Rubric changed (rubric-2026.10.5 → rubric-2026.11.4) — scores are not directly comparable.

Lenses

  • Code Health 45 → 45 (-0.2)
  • Architecture 97 → 97 (+0.0)
  • Maturity 54 → 52 (-1.5)
  • Readiness 91 → 91 (+0.0)
  • Security 65 → 65 (+0.0)

Resolved (4)

  • Ambiguous distinction between getRoot() and getRootMethodCall(). Both suggest retrieving the root/original method in a chain of calls (e.g., through macros or proxies). The difference in return type or semantic meaning is not obvious from the signature alone, risking confusion.
  • Documentation: no project overview (README.md)
  • Inconsistent naming pattern for property extraction. getPropertiesFromTable and getPropertiesFromMethods follow a 'getPropertiesFrom[Source]' pattern, while castPropertiesType implies a transformation or casting operation rather than extraction. It is unclear if castPropertiesType is a helper for the other two or a distinct third source of properties.
  • TodoComment repeated across 14 files (tests/Console/ModelsCommand/LaravelCustomCasts/Casts/SelfCastingCasterWithThisDocblockReturn.php)

New (3)

  • Edited copy of a member (27 corresponding lines) (src/Console/ModelsCommand.php)
  • Hotspot: src/Console/ModelsCommand.php (src/Console/ModelsCommand.php)
  • TodoComment repeated across 14 files (tests/Console/ModelsCommand/LaravelCustomCasts/Casts/CastableReturnsAnonymousCaster.php)

Changes since last survey

  • 2 commits — 1 feature/other, 1 fixes

By area

  • (root) — 1 commit
  • tests/Console — 1 commit

Notable commits

  • fix: fix: only add <static> to builder annotations for generic builders (#1803)
  • change: Update CHANGELOG

Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

barryvdh/laravel-ide-helper was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 13 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 66f7ec11122bcb009aba7c2fea31faf5cee46634 — the exact code this score is about.
  • Scored under rubric-2026.11.4 — the same rubric and the same method as every other entry in this index.
  • Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.64+preprod-569132d3dfbe.