-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sharp and webpack 2 support (aka v1 π) #29
Conversation
Snapshots FTW
Hopefully this solves the sharp build issue
Any chance you'll merge this soon? Anything I can do to help getting this done? |
Node 4 is not the LTS release anymore. Code is still transpiled for it though.
The performance improvement is dramatic with this patch. I hope you can merge it soon. |
Somebody published this branch as a separate package to NPM: https://www.npmjs.com/package/responsive-loader-sharp, feel free to use that in the meantime. |
That package's README is wrong. I will try to finish the remaining work in the next few days and release an "official" version. |
β¦ maybe sharp produces consistent results by now
Alright, I've just published Along the way, I dropped support for webpack 1 and had to change the import syntax a bit. Make sure to read the change log and the new README. Please test this release and then we'll finally get it out the door π . Thanks for the patience! PS: I'll be adding the pending new features once this is done. |
I won't be able to test this because my current project still uses webpack 1, and I don't plan to upgrade to webpack 2 in this iteration. |
Works great. Thanks. |
Merged and released as |
Adds support for processing images using sharp which is much faster than Jimp or even ImageMagick.
I built on top of @langri-sha's work mentioned in #2, but instead of replacing Jimp, I added sharp as an option. Currently, you can enable it by specifying it as an
adapter
in the webpack config (default is still Jimp):Auto-detection of sharp could still be added. This approach has the nice benefit that anyone can supply their own adapters once the API is stable.
I also reorganized and changed a few things, most notably:
After some fiddling I got the tests to pass on Travis. sharp builds fine on the
trusty
environment but oddly the output of sharp seems to differ on Linux and macOS, so I had to switch to theosx
environment in order to make the tests pass. I wonder if there's a better solution to this β¦