5562daf7a1
Fixes #18415 by using the default config as fallback. Users who wish to use their `next.config.js` values will still need the workaround from https://github.com/vercel/next.js/issues/18415#issuecomment-718180659
24 lines
511 B
TypeScript
24 lines
511 B
TypeScript
export const VALID_LOADERS = [
|
|
'default',
|
|
'imgix',
|
|
'cloudinary',
|
|
'akamai',
|
|
] as const
|
|
|
|
export type LoaderValue = typeof VALID_LOADERS[number]
|
|
|
|
export type ImageConfig = {
|
|
deviceSizes: number[]
|
|
imageSizes: number[]
|
|
loader: LoaderValue
|
|
path: string
|
|
domains?: string[]
|
|
}
|
|
|
|
export const imageConfigDefault: ImageConfig = {
|
|
deviceSizes: [640, 750, 828, 1080, 1200, 1920, 2048, 3840],
|
|
imageSizes: [16, 32, 48, 64, 96, 128, 256, 384],
|
|
path: '/_next/image',
|
|
loader: 'default',
|
|
domains: [],
|
|
}
|