Source: ryangjchandler.co.uk

Caching chunks of your Blade templates
Caching chunks of your Blade templates As your application grows it's likely that your Blade templates will become more and more complex.

With this package you can cache a chunk of your Blade template and avoid unnecessary recompilation in future renders.

Now find the part of your Blade template that you'd like to cache and wrap it in a @cache directive.

Since this package uses Laravel's Cache setup, clearing the cached chunk of Blade is as simple as calling Cache::forget('heavy-bit-of-blade') or clearing the application cache on deployment.
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Achieve superior email deliverability with ToastMail! Our AI-driven tool warms up inboxes, monitors reputation, and ensures emails reach their intended destination. Sign up today for a spam-free future. Achieve superior email deliverability with ToastMail! Our AI-driven tool warms up inboxes, monitors reputation, and ensures emails reach their intended destination. Sign up today for a spam-free future.
Community Partners