Reputation: 1531
I have a routing.yml file where I define the routes of my bundle. My routing file is growing bigger.
Is there a way to split the routing.yml file in multiple files? Eg:
NOTE: I am using Symfony 2.2;
Upvotes: 6
Views: 5302
Reputation: 2285
The routing.yml can split by multiple files. You can include separate routing files in your routing.yml file.
acme_demo_user:
resource: "@acmeDemoBundle/Resources/config/routing/user_routing.yml"
prefix: /user
acme_demo_vehicles:
resource: "@acmeDemoBundle/Resources/config/routing/vehicles_routing.yml"
prefix: /vehicles
.............
.............
Upvotes: 18