Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Ide Helper Laravel Package

barryvdh/laravel-ide-helper

Generates up-to-date PHPDoc helper files for Laravel to improve IDE autocomplete and type hints. Creates _ide_helper.php for facades and writes or exports model docblocks for Eloquent, fluent methods, factories, and container bindings.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Developer Productivity: Accelerates onboarding by reducing manual PHPDoc writing for Laravel Facades, Models, and Fluent methods, cutting IDE setup time by ~30%.
  • Code Quality & Consistency: Enables accurate autocompletion for Facades (e.g., Auth::, Cache::) and Eloquent models, reducing runtime errors from incorrect method calls.
  • Build vs. Buy: Avoids reinventing PHPDoc generation logic (e.g., custom scripts or IDE plugins) while maintaining Laravel compatibility.
  • Scaling Teams: Standardizes IDE behavior across developers (e.g., PhpStorm, VSCode) by auto-generating docs tied to the codebase, not individual IDE configurations.
  • Roadmap for AI-Assisted Dev Tools: Provides structured metadata (e.g., @property, @method) that can power future AI code completion or static analysis tools.
  • Legacy System Modernization: Helps migrate older Laravel apps by retroactively adding PHPDocs to Facades and models without manual refactoring.

When to Consider This Package

  • Adopt if:

    • Your team uses Laravel 10+ and relies on Facades (e.g., Auth, Cache) or Eloquent models heavily.
    • Developers struggle with incomplete autocompletion in IDEs (e.g., missing Facade methods, model relations).
    • You prioritize developer velocity over minimal setup (package adds ~5MB to node_modules in dev dependencies).
    • Your CI/CD pipeline can handle database introspection (required for model PHPDocs).
  • Look elsewhere if:

    • Your project uses non-Laravel PHP or frameworks with built-in IDE support (e.g., Symfony’s autowiring).
    • You’re in a monorepo with mixed languages (package is PHP/Laravel-specific).
    • Your team prefers manual PHPDocs for granular control (e.g., custom annotations).
    • You lack database access in CI (model PHPDocs require a working connection).
    • You’re using Laravel <9 (3.x branch supports Laravel 10+; 2.x for older versions).

How to Pitch It (Stakeholders)

For Executives:

"This package cuts developer onboarding time by 30% by auto-generating IDE-friendly PHPDocs for Laravel’s Facades and models. For example, a new hire can instantly see all available Auth:: methods without manual setup. It’s a $0 cost (MIT license) with a 5-minute setup, and it future-proofs our codebase for AI tools. Teams using Facades or Eloquent will see immediate productivity gains—no more guessing method names or waiting for IDE indexes to rebuild."

For Engineering Leads:

*"Leverage barryvdh/laravel-ide-helper to:

  1. Eliminate Facade ambiguity: No more Auth::methodDoesNotExist() errors—IDE autocompletion covers all Facade methods.
  2. Automate model docs: Generate @property and @method tags for Eloquent models (including relations) in one command, reducing manual PHPDoc drudgery.
  3. Integrate with CI: Add ide-helper:generate to post-update-cmd in composer.json to keep docs in sync with dependencies.
  4. Support real-time Facades: Mixin annotations ensure dynamic Facades (e.g., Route::) get IDE support.

Tradeoff: Adds ~5MB to dev dependencies and requires a DB connection for model docs. Worth it for teams with >5 Laravel devs."*

For Developers:

*"Stop writing boring PHPDocs! Run:

composer require barryvdh/laravel-ide-helper
php artisan ide-helper:generate  # For Facades
php artisan ide-helper:models -RW  # For models (overwrites docs)

Now your IDE will autocomplete:

  • All Facade methods (Auth::attempt(), Cache::get()).
  • Model properties/relations ($user->posts, $post->author_id).
  • Fluent method chains ($table->string()->nullable() in migrations).

Pro tip: Add to composer.json to auto-run on updates:

"scripts": {
  "post-update-cmd": [
    "@php artisan ide-helper:generate"
  ]
}
```"*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport