Example: CRUD Module
Generate complete CRUD module with one command.
Quick CRUD Generation
bin/console make:hexagonal:crud blog/post Post --with-tests --with-id-vo --route-prefix=/posts
This generates 30+ files:
- Entity + Repository + ID ValueObject
- 5 Use Cases (Create, Update, Delete, Get, List)
- 5 Controllers + Form
- All tests
Generated Routes
GET /posts- List all postsGET /posts/{id}- Show single postGET /posts/new- Create formPOST /posts/new- Submit new postGET /posts/{id}/edit- Edit formPOST /posts/{id}/edit- Submit updateDELETE /posts/{id}/delete- Delete post
Next Steps
- Complete Doctrine mapping
- Configure module in
doctrine.yaml - Generate migrations
- Test your CRUD!
See Quick Start for full tutorial.