@codefast/image-loader
Version:
Simple, functional image loader for Next.js supporting multiple CDN providers
13 lines (12 loc) • 377 B
TypeScript
import type { ImageLoaderProps } from "next/image";
/**
* AWS CloudFront URL transformation
* Handles *.cloudfront.net domains
*
* @example
* ```text
* https://d1234567890.cloudfront.net/image.jpg
* → https://d1234567890.cloudfront.net/image.jpg?f=auto&q=80&w=800
* ```
*/
export declare function cloudfrontLoader({ quality, src, width }: ImageLoaderProps): string;