Comments (3)
The examples you've given are for the confusingly named Cloudflare Images rather than Cloudflare Image Resizing, which is what the current one handles. I'd not realised that Cloudflare Images supported dynamic resizing too, but I see it can be enabled with "flexible variants". If someone wants to contribute support for the flexible variants syntax with Cloduflare Images that would be great. If that happened, we could add imagedelivery.net
to detected domains too.
from unpic.
I see that now, my apologies. Wow! That is confusing then on their part to have similar products with similar names.
I would contribute the syntax myself, but I am afraid my coding skills are not up to snuff. 😅
from unpic.
I'm using the Image Resizing service as well and having a bit of trouble. I have a properly formatted path for my CF image: https://cdn.romamoulding.com/cdn-cgi/image//https://cdn.romamoulding.com/mouldings/753-1.png
however I'm receiving Invalid Cloudflare URL
as an error.
This seems related to the strictness of the transformations group requiring certain input. I'd like to recommend making it optional:
https?:\/\/(?<host>[^\/]+)\/cdn-cgi\/image\/(?<transformations>[^\/]+)?\/(?<path>.*)$
I can certainly submit a PR to fix it. Edit: PR is here: #60
The thing about CF Image Resizing is that it also allows you to proxy the requests through a custom worker for serving up images ie. I have this setup: https://images.romamoulding.com/?image=https://cdn.romamoulding.com/mouldings/753-1.png which is equivalent to the above cdn path.
I suppose the way to do this with Unpic is to allow the domain images.romamoulding.com
and assert cdn as cloudflare
. Wouldn't the Regex however block this allowance though since it doesn't have the cdn-cgi path in it.
from unpic.
Related Issues (20)
- Add support for cloudimage HOT 1
- Add support for statically
- Add Deno basics to CONTRIBUTING.md HOT 2
- Astro types broken HOT 1
- Astro transformer format HOT 5
- Can you support cloudflare-image without custom domain? HOT 1
- Working with Cloudinary video thumbnails
- Shopify cdn not detected when url doesn't include cdn.shopify.com
- Imagekit - wrong format parameter (fm instead of f) HOT 3
- Add support for wsrv.nl HOT 1
- Proposal : add an option to opt out of automated url delegation HOT 4
- Could you add Supabase Storage Image CDN (public urls) HOT 2
- Bug: regex won't match valid cloudflare image url's
- Add `position` prop to support all Builder params HOT 1
- How can I display private domain cdn images? HOT 4
- Dynamic Cloudinary url gets truncated in Unpic srcset HOT 1
- Can't recognize a valid cloudinary url HOT 2
- Pass in own transformer
- feature: support Astro transformer
- Core as a set of plugins HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from unpic.