How to prevent code duplication in controllers?

Hi all :slight_smile: Hope you are enjoying this time of the year as much as I do!

Question about controllers. I have a wee bit of code that I need in most my pages‘ controllers.

Is there a specific way to remove such code from the controllers and move it to a single place, subsequently referencing to it from the controllers?

Thanks
Sascha

What sort of information is duplicated? There are several ways to prevent this, but the best way to achieve that depends on your code.

Options:

God. Please tell me shared controllers is a spanking new feature?!

I thought I had a thorough look at the docs.

Thank you Sonja, as always.