- What is the Laravel Porto package and what does it actually generate?
- It is a scaffolding and architecture-enablement tool for adopting the Porto pattern in Laravel, organizing code into containers and reusable components. It uses Artisan generators and publishable config and stubs to create structures like app/Containers/{Section}/{Container}/{UI, Actions, Tasks, Models, Data, Values}. It is not a runtime library, so most of its value is conventions and generated code rather than runtime abstractions. Confirm in the source whether it also ships base Action, Task, or Repository classes.
- How do I install ibecsystems/laravel-porto in a Laravel application?
- Install it as a dev dependency with composer require --dev ibecsystems/laravel-porto, then publish its config and stubs and run the provided Artisan generators. Expect PSR-4 namespace additions such as App\Containers\ and optional per-container service providers for routes and events. Before committing, run composer why-not against your Laravel version to verify constraints and namespace compatibility.
- Does laravel-porto support Laravel 10, 11, or 12?
- The package has a single release dated April 2024 and no visible community verification of Laravel or PHP version constraints. Stub drift against Laravel 10, 11, or 12 conventions is likely, so do not assume compatibility. Run composer why-not laravel/framework and test generation on your current LTS before adopting it.
- Is laravel-porto a runtime dependency or a dev-only tool?
- It is primarily a dev-only tool: install it with --dev, publish stubs, and generate scaffolding. There is no meaningful production runtime surface, so vulnerability exposure is limited to dev tooling and the quality of generated code. The generated code becomes your application code, so review and adapt the stubs carefully.
- Can I use laravel-porto in an existing Laravel app or only greenfield projects?
- It fits greenfield projects or new bounded contexts best, but it is a poor retrofit over an existing conventional Laravel layout with app/Models and app/Http/Controllers. Introduce it for new containers only and leave existing application structure untouched. Validate the approach with one real feature slice before expanding adoption.
- How does laravel-porto compare to laravel-modules or Apiato?
- It shares container and module conventions with those tools but is much smaller and less maintained, with a single release and minimal CI signal. Do not run it alongside laravel-modules or Apiato in the same tree, because overlapping module and container conventions will confuse autoloading and route registration. Check whether it is a fork or derivative of Apiato or Mahmoud Zalt's Porto work so you track the right upstream.
- Are the stubs customizable, and can I vendor them into my own repository?
- The package publishes config and stubs, so you can adapt the generated scaffolding to your team conventions. If upstream maintenance becomes a concern, vendor the stubs into your repository or a private Composer package and drop the external dependency. That keeps the Porto pattern without the supply-chain and longevity liability.
- Does laravel-porto enforce architecture boundaries or just create folders?
- The evidence points to scaffolding only; there is no clear signal of architecture tests, Deptrac, or PHPStan rules. You must add your own Pest, PHPStan, or Deptrac checks to enforce container boundaries and layering. Confirm whether it ships base abstractions for Actions, Tasks, and Repositories or only directory structures.
- Is laravel-porto safe for production, and what are the supply-chain risks?
- Security risk is low because it is a dev-only tooling package, but longevity risk is high: one star, zero dependents, a single 2024 release, and effectively a bus factor of one. Treat abandonment as likely and avoid making it a critical dependency. Fork or vendor the stubs and record the decision in an ADR.
- How should I pilot laravel-porto and sequence adoption in my team?
- Run a throwaway-branch spike that generates one real container with an Action, Task, Model, route, and test end-to-end. Measure developer feedback and decide within one to two weeks whether to adopt, fork, vendor the stubs, or reject. If adopted, codify the stubs, add architecture tests, and update onboarding documentation.