Fix broken images on live site with cache-busting and proper headers
Cloudflare was caching 404 responses from before the tunnel was configured. Added query params to bust stale cached 404s for featured.jpg and goddess.webp. Added Cache-Control headers for /images/* to ensure proper long-term caching. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
05aa076eb5
commit
96172427fc
|
|
@ -2,6 +2,30 @@ import type { NextConfig } from "next";
|
||||||
|
|
||||||
const nextConfig: NextConfig = {
|
const nextConfig: NextConfig = {
|
||||||
output: "standalone",
|
output: "standalone",
|
||||||
|
images: {
|
||||||
|
localPatterns: [
|
||||||
|
{
|
||||||
|
pathname: "/images/**",
|
||||||
|
search: "?v=*",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
pathname: "/images/**",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
async headers() {
|
||||||
|
return [
|
||||||
|
{
|
||||||
|
source: "/images/:path*",
|
||||||
|
headers: [
|
||||||
|
{
|
||||||
|
key: "Cache-Control",
|
||||||
|
value: "public, max-age=31536000, immutable",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
];
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
export default nextConfig;
|
export default nextConfig;
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,7 @@ function RitualArtSection() {
|
||||||
{/* Featured Art Image */}
|
{/* Featured Art Image */}
|
||||||
<div className="relative aspect-[3/4] rounded-2xl overflow-hidden shadow-xl">
|
<div className="relative aspect-[3/4] rounded-2xl overflow-hidden shadow-xl">
|
||||||
<Image
|
<Image
|
||||||
src="/images/art/featured.jpg"
|
src="/images/art/featured.jpg?v=2"
|
||||||
alt="Visionary Art by Ximena Xaguar"
|
alt="Visionary Art by Ximena Xaguar"
|
||||||
fill
|
fill
|
||||||
className="object-cover"
|
className="object-cover"
|
||||||
|
|
@ -162,7 +162,7 @@ function RitualArtSection() {
|
||||||
// Art Gallery Section
|
// Art Gallery Section
|
||||||
function GallerySection() {
|
function GallerySection() {
|
||||||
const artworks = [
|
const artworks = [
|
||||||
{ src: '/images/art/goddess.webp', title: 'Goddess' },
|
{ src: '/images/art/goddess.webp?v=2', title: 'Goddess' },
|
||||||
{ src: '/images/art/mujer-medicina.webp', title: 'Mujer Medicina' },
|
{ src: '/images/art/mujer-medicina.webp', title: 'Mujer Medicina' },
|
||||||
{ src: '/images/art/shiva-main.webp', title: 'Shiva' },
|
{ src: '/images/art/shiva-main.webp', title: 'Shiva' },
|
||||||
{ src: '/images/art/twin-flames.webp', title: 'Twin Flames' },
|
{ src: '/images/art/twin-flames.webp', title: 'Twin Flames' },
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue