rsnext/packages/next/server
Steven b123942694
Fix minimumCacheTTL so it doesn't affect browser caching (#27307)
In a previous PR (#27200), we added `minimumCacheTTL` to configure the time-to-live for the cached image. However, this was setting the `max-age` header.

This PR ensures that `minimumCacheTTL` doesn't affect browser caching, only the upstream header can affect browser caching.

This is a bit safer in case the developer accidentally caches something that shouldn't be and the cache needs to be invalidated. Simply delete the `.next/cache/images` directory.

- Related to #19914
- Related to #22319
2021-07-19 22:38:03 +00:00
..
dev Add some missing fields to the NextConfig type (#27126) 2021-07-12 21:38:57 +00:00
lib Workaround for Node.js 16+ on Apple Silicon M1 (#27031) 2021-07-12 17:05:41 +00:00
api-utils.ts Include message body in redirect responses (#25257) 2021-07-09 16:32:48 +00:00
config-shared.ts improve static generation UX (#27171) 2021-07-16 09:21:44 +00:00
config-utils-worker.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
config-utils.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
config.ts Add minimumCacheTTL config for Image Optimization (#27200) 2021-07-15 19:55:12 +00:00
crypto-utils.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
denormalize-page-path.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
font-utils.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
get-page-files.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
get-route-from-entrypoint.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
htmlescape.ts Upgrade to Prettier 2 (#13061) 2020-05-18 15:24:37 -04:00
image-config.ts Add minimumCacheTTL config for Image Optimization (#27200) 2021-07-15 19:55:12 +00:00
image-optimizer.ts Fix minimumCacheTTL so it doesn't affect browser caching (#27307) 2021-07-19 22:38:03 +00:00
incremental-cache.ts More explicit typing for IncrementalCache API (#26941) 2021-07-06 15:45:49 +00:00
load-components.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
next-server.ts Add x-forward headers to external rewrites (#17557) 2021-07-16 10:11:12 -05:00
next.ts Use SWC to compile Next.js core server files (#27167) 2021-07-14 18:12:04 +00:00
node-polyfill-fetch.js Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
normalize-page-path.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
optimize-amp.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
render.tsx Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
require.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
response-cache.ts Replace withCoalescedInvoke with ResponseCache (#26997) 2021-07-12 19:47:39 +00:00
router.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
send-payload.ts Replace withCoalescedInvoke with ResponseCache (#26997) 2021-07-12 19:47:39 +00:00
serve-static.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00
utils.ts Move next-server directory files to server directory (#26756) 2021-06-30 13:44:40 +02:00