Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
N
next.js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex
next.js
Commits
fda6986b
Unverified
Commit
fda6986b
authored
May 20, 2026
by
Hendrik Liebau
Committed by
GitHub
May 20, 2026
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[test] Prerendering HTTP access fallback pages with Cache Components (#93987)
parent
3e97d89d
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
486 additions
and
0 deletions
+486
-0
cache-components-errors.http-access-fallback-prerender.test.ts
...-components-errors.http-access-fallback-prerender.test.ts
+384
-0
forbidden.tsx
...ess-fallback-prerender/app/forbidden/[slug]/forbidden.tsx
+9
-0
page.tsx
...p-access-fallback-prerender/app/forbidden/[slug]/page.tsx
+19
-0
layout.tsx
...rs/fixtures/http-access-fallback-prerender/app/layout.tsx
+7
-0
not-found.tsx
...ess-fallback-prerender/app/not-found/[slug]/not-found.tsx
+9
-0
page.tsx
...p-access-fallback-prerender/app/not-found/[slug]/page.tsx
+19
-0
page.tsx
...ccess-fallback-prerender/app/unauthorized/[slug]/page.tsx
+19
-0
unauthorized.tsx
...llback-prerender/app/unauthorized/[slug]/unauthorized.tsx
+9
-0
next.config.js
...rs/fixtures/http-access-fallback-prerender/next.config.js
+11
-0
No files found.
test/e2e/app-dir/cache-components-errors/cache-components-errors.http-access-fallback-prerender.test.ts
0 → 100644
View file @
fda6986b
This diff is collapsed.
Click to expand it.
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/forbidden/[slug]/forbidden.tsx
0 → 100644
View file @
fda6986b
'use client'
import
{
useSearchParams
}
from
'next/navigation'
export
default
function
Forbidden
()
{
const
searchParams
=
useSearchParams
()
return
<
p
>
forbidden
{
searchParams
.
get
(
'foo'
)
}
</
p
>
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/forbidden/[slug]/page.tsx
0 → 100644
View file @
fda6986b
import
{
forbidden
}
from
'next/navigation'
export
function
generateStaticParams
()
{
return
[{
slug
:
'allowed'
},
{
slug
:
'forbidden'
}]
}
export
default
async
function
Page
({
params
,
}:
{
params
:
Promise
<
{
slug
:
string
}
>
})
{
const
{
slug
}
=
await
params
if
(
slug
===
'allowed'
)
{
return
<
p
>
hello world
</
p
>
}
forbidden
()
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/layout.tsx
0 → 100644
View file @
fda6986b
export
default
function
Root
({
children
}:
{
children
:
React
.
ReactNode
})
{
return
(
<
html
>
<
body
>
{
children
}
</
body
>
</
html
>
)
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/not-found/[slug]/not-found.tsx
0 → 100644
View file @
fda6986b
'use client'
import
{
useSearchParams
}
from
'next/navigation'
export
default
function
NotFound
()
{
const
searchParams
=
useSearchParams
()
return
<
p
>
not found
{
searchParams
.
get
(
'foo'
)
}
</
p
>
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/not-found/[slug]/page.tsx
0 → 100644
View file @
fda6986b
import
{
notFound
}
from
'next/navigation'
export
function
generateStaticParams
()
{
return
[{
slug
:
'found'
},
{
slug
:
'not-found'
}]
}
export
default
async
function
Page
({
params
,
}:
{
params
:
Promise
<
{
slug
:
string
}
>
})
{
const
{
slug
}
=
await
params
if
(
slug
===
'found'
)
{
return
<
p
>
hello world
</
p
>
}
notFound
()
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/unauthorized/[slug]/page.tsx
0 → 100644
View file @
fda6986b
import
{
unauthorized
}
from
'next/navigation'
export
function
generateStaticParams
()
{
return
[{
slug
:
'authorized'
},
{
slug
:
'unauthorized'
}]
}
export
default
async
function
Page
({
params
,
}:
{
params
:
Promise
<
{
slug
:
string
}
>
})
{
const
{
slug
}
=
await
params
if
(
slug
===
'authorized'
)
{
return
<
p
>
hello world
</
p
>
}
unauthorized
()
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/app/unauthorized/[slug]/unauthorized.tsx
0 → 100644
View file @
fda6986b
'use client'
import
{
useSearchParams
}
from
'next/navigation'
export
default
function
Unauthorized
()
{
const
searchParams
=
useSearchParams
()
return
<
p
>
unauthorized
{
searchParams
.
get
(
'foo'
)
}
</
p
>
}
test/e2e/app-dir/cache-components-errors/fixtures/http-access-fallback-prerender/next.config.js
0 → 100644
View file @
fda6986b
/**
* @type {import('next').NextConfig}
*/
const
nextConfig
=
{
cacheComponents
:
true
,
experimental
:
{
authInterrupts
:
true
,
},
}
module
.
exports
=
nextConfig
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment