AniX/next.config.js
2025-02-10 06:31:40 +05:00

77 lines
1.7 KiB
JavaScript

const { withPlausibleProxy } = require("next-plausible");
module.exports = withPlausibleProxy({
customDomain: "https://analytics.wah.su",
})({
reactStrictMode: false,
images: {
unoptimized: true,
},
async headers() {
return [
{
source: '/bookmarks/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/collection/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/home/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/profile/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/release/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/related/:slug*',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
{
source: '/search',
headers: [
{
key: 'Cache-Control',
value: 's-maxage=2592000, stale-while-revalidate=86400',
},
],
},
];
},
});