【发布时间】:2022-11-10 23:08:52
【问题描述】:
NextJS 文档特别指出 (https://nextjs.org/docs/api-reference/next.config.js/headers#cache-control):
You cannot set Cache-Control headers in next.config.js file as these will be overwritten in production to ensure that API Routes and static assets are cached effectively.
在 NextJS 中缓存图像资产的另一种方法是什么?
我尝试使用 NextJS Image 组件,但是它将我的自托管图像 url 与专有的 NextJS url 混淆了。我想逃避那个。
【问题讨论】:
标签: next.js nextjs-image