vkorobtsev-nextJs/next.config.js

28 lines
494 B
JavaScript
Raw Normal View History

2023-09-05 20:06:59 +07:00
const withBundleAnalyzer = require("@next/bundle-analyzer")({
enabled: process.env.ANALYZE === "true",
});
module.exports = withBundleAnalyzer({
// your Next.js configuration
2024-02-12 18:51:36 +07:00
webpack: (config, options) => {
config.module.rules.push({
test: /\.pdf$/i,
type: "asset/source",
});
return config;
},
2023-09-06 22:05:49 +07:00
async headers() {
return [
{
source: "/sitemap.xml.gz",
headers: [
{
key: "Content-Type",
value: "application/gzip",
},
],
},
];
},
2023-09-05 20:06:59 +07:00
});