Disable routing cache in symfony

I'm trying to get started with symfony3 and when playing with some controllers and routes, I run into the problem that every time I load a specific route, any further changes to the controller class are not recognized by symfony until I clear the cache routing.

For instance:

creation of LuckyController

creating numberAction

Check it out.

After that, create the number 2Action

Now the route for numbers2Action is not found until I make a cache console: clear

This seems very annoying for testing / development. I was looking for ways to disable the cache for the dev environment, but have not yet found a solution. (for example, tried // $ kernel-> loadClassCache (), in app_dev.php, but that did not help me)

Is there a way to disable the routing cache (or another way to solve this problem) for development?

thanks

Edit: I am using app_dev.php

+5
source share
1 answer

There is a special development environment that comes with the Symfony standard, which you can use when developing or debugging your application: app_dev.php , you can use app.php for production.

+2
source

Source: https://habr.com/ru/post/1241352/


All Articles