-
-
Notifications
You must be signed in to change notification settings - Fork 13
Description
An interesting case brought up at the Laravel Meetup in Malmö was using the asset build pipeline to manipulate images. Had an idea on how to make this even easier to hook into. We could instead of copying files in the build process, call a compile/similar method on the instance. The default implementation is to return a binary copy of the source file that we write to disk, but a developer could create a custom media class that could for example override this method to read the source file, compress it, and return the compressed file binary contents which we then write. We would need a way to support swapping out the class so I feel this is something we can do at a later time, but we should add the plumbing to support the root stuff here.
Originally posted by @caendesilva in #1904 (comment)