minor: configure image formats in nuxt.config.ts
This commit is contained in:
@@ -12,7 +12,6 @@ defineProps<{ image?: AcfImageFragment }>();
|
|||||||
:width="image.mediaDetails?.width"
|
:width="image.mediaDetails?.width"
|
||||||
:height="image.mediaDetails?.height"
|
:height="image.mediaDetails?.height"
|
||||||
:style="{ objectPosition: image.objectPosition || 'center' }"
|
:style="{ objectPosition: image.objectPosition || 'center' }"
|
||||||
format="avif,webp"
|
|
||||||
placeholder
|
placeholder
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -102,8 +102,10 @@ export default defineNuxtConfig({
|
|||||||
},
|
},
|
||||||
|
|
||||||
image: {
|
image: {
|
||||||
...isDev ? {} : { provider: "cloudflare", cloudflare: { baseURL: "/" } },
|
provider: isDev ? "ipx" : "cloudflare",
|
||||||
|
cloudflare: { baseURL: `${siteUrl}/` },
|
||||||
domains: [wpDomain],
|
domains: [wpDomain],
|
||||||
|
format: ["avif", "webp"],
|
||||||
},
|
},
|
||||||
|
|
||||||
robots: {
|
robots: {
|
||||||
|
|||||||
Reference in New Issue
Block a user