Answer the question
In order to leave comments, you need to log in
How to pass symfony response through some filter, process output?
Greetings!
Everything that symfony outputs to the browser must be passed through some kind of processing. For example, replace external links with away?to=... and more.
How to do this with regular symfony or twig tools or in some other way, it is desirable that the result be cached.
Answer the question
In order to leave comments, you need to log in
Through events. Intercept the response event, change what you need, return a new Response object
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question