Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
- Fix Next.js dynamic and static OG images. (#6592)
- Address a regression introduced in 13.0.1 when emulating Vite applications. (#6599)
- Add RSC headers of Next.js app directory pages to Hosting headers. (#6608)
30 changes: 30 additions & 0 deletions scripts/webframeworks-deploy-tests/tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,36 @@ describe("webframeworks", function (this) {
},
],
},
{
headers: [
{
key: "x-next-cache-tags",
value:
"_N_T_/layout,_N_T_/app/layout,_N_T_/app/image/layout,_N_T_/app/image/page,_N_T_/app/image",
},
],
source: "/base/app/image",
},
{
headers: [
{
key: "x-next-cache-tags",
value:
"_N_T_/layout,_N_T_/app/layout,_N_T_/app/ssg/layout,_N_T_/app/ssg/page,_N_T_/app/ssg",
},
],
source: "/base/app/ssg",
},
{
headers: [
{
key: "x-next-cache-tags",
value:
"_N_T_/layout,_N_T_/app/layout,_N_T_/app/isr/layout,_N_T_/app/isr/page,_N_T_/app/isr",
},
],
source: "/base/app/isr",
},
],
cleanUrls: true,
trailingSlash: false,
Expand Down
2 changes: 1 addition & 1 deletion src/frameworks/next/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ export async function getHeadersFromMetaFiles(

await Promise.all(
Object.entries(appPathRoutesManifest).map(async ([key, source]) => {
if (basename(key) !== "route") return;
if (!["route", "page"].includes(basename(key))) return;
const parts = source.split("/").filter((it) => !!it);
const partsOrIndex = parts.length > 0 ? parts : ["index"];

Expand Down