question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Combine resizing with other options like webp

See original GitHub issue

Would it be possible to stack resize with another parameter like webp? Currently it seems it’s either or. Right now I can only do this in css :

.webp .bgimage {
	background-image: url('../static/images/bg.jpg?webp'); // will be over-sized
}
.no-webp .bgimage {
	background-image: url('../static/images/bg.jpg?resize&size=520');
}

Ideally I’d like to do this :

.webp .bgimage {
	background-image: url('../static/images/bg.jpg?webp&resize&size=520');
}
.no-webp .bgimage {
	background-image: url('../static/images/bg.jpg?resize&size=520');
}

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:35
  • Comments:7

github_iconTop GitHub Comments

1reaction
benedfitcommented, Feb 20, 2021

Have you tried ?resize&format=webp?

1reaction
akd-iocommented, Feb 3, 2020

I’m having difficulty with this as well 😕

Edit: Seems like a common issue here. #120 mentions it and references relevant issues, #84 and #91. Quote from issue #120:

I’m not 100% happy with the current version for the following reasons:

  • it depends on many different webpack loaders which has led to some workarounds and many features cannot be combined because the loaders don’t work well with each other. See #84, #91 for examples.
Read more comments on GitHub >

github_iconTop Results From Across the Web

Free Online Resize WEBP Images with High output Quality
Integrate WEBP Resize feature in your own projects. This free resize tool is based on Aspose.Imaging for .NET, which is a fast API...
Read more >
TinyPNG – Compress WebP, PNG and JPEG images ...
TinyPNG optimizes your WebP, PNG and JPEG images by 50-80% while preserving ... (Portable Network Graphics) file, similar colors in your image are...
Read more >
Auto-Resize All Images at Once with Photoshop for Web or E ...
4 Simple Steps to Resize Multiple Images Using Image Processor in Photoshop! Learn how to batch reduce the image file size for web,...
Read more >
How to RESIZE IMAGES for WEB using Photoshop (also GIMP ...
In this video, I show you how to quickly resize and optimize your images for the web using Photoshop, GIMP, Lightroom, and Luninar....
Read more >
Resize, crop and other common transformations
If only, one of the height(h) or width(w) dimensions is specified, then ImageKit.io adjusts the other dimension accordingly to preserve aspect ratio and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found