Support the ongoing development of Laravel.io →
Views Blade Architecture
Last updated 1 year ago.
0

Are you sure all dependencies belong into your controller? Does your controller need to care about all the tasks that are going on there?

If not you could consider to outsource certain tasks into own services and slim down your controller a bit.

Would you be able to post the code your controller, so we can take a further look into it?

Last updated 1 year ago.
0

View controllers may also be what you're looking for here to help reduce controller deps

Last updated 1 year ago.
0

machuga said:

View controllers may also be what you're looking for here to help reduce controller deps

I'm assuming you mean View Composers? Yes, I actually looked into these after I wrote this post - I think they are my best option at this point.

Last updated 1 year ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

cmgmyr cmgmyr Joined 9 Apr 2014

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.