first commit
Some checks failed
Test examples / Test Examples (20) (push) Has been cancelled
Test examples / Test Examples (22) (push) Has been cancelled
Lock Threads / action (push) Has been cancelled
Trigger Release / start (push) Has been cancelled
Stale issue handler / stale (push) Has been cancelled
Update Font Data / create-pull-request (push) Has been cancelled
build-and-deploy / deploy-target (push) Has been cancelled
build-and-deploy / build (push) Has been cancelled
build-and-deploy / stable - aarch64-unknown-linux-musl - node@16 (push) Has been cancelled
build-and-deploy / stable - x86_64-unknown-linux-musl - node@16 (push) Has been cancelled
build-and-deploy / stable - aarch64-unknown-linux-gnu - node@16 (push) Has been cancelled
build-and-deploy / stable - x86_64-unknown-linux-gnu - node@16 (push) Has been cancelled
build-and-deploy / stable - aarch64-pc-windows-msvc - node@16 (push) Has been cancelled
build-and-deploy / stable - x86_64-pc-windows-msvc - node@16 (push) Has been cancelled
build-and-deploy / stable - aarch64-apple-darwin - node@16 (push) Has been cancelled
build-and-deploy / stable - x86_64-apple-darwin - node@16 (push) Has been cancelled
build-and-deploy / build-wasm (nodejs) (push) Has been cancelled
build-and-deploy / build-wasm (web) (push) Has been cancelled
build-and-deploy / Deploy preview tarball (push) Has been cancelled
build-and-deploy / Potentially publish release (push) Has been cancelled
build-and-deploy / publish-turbopack-npm-packages (push) Has been cancelled
build-and-deploy / Deploy examples (push) Has been cancelled
build-and-deploy / thank you, build (push) Has been cancelled
build-and-deploy / Upload Turbopack Bytesize metrics to Datadog (push) Has been cancelled
Rspack Next.js development integration tests / Rspack integration tests (push) Has been cancelled
Rspack Next.js production integration tests / Rspack integration tests (push) Has been cancelled
Turbopack Next.js development integration tests / Next.js integration tests (push) Has been cancelled
Turbopack Next.js production integration tests / Next.js integration tests (push) Has been cancelled
Update Rspack test manifest / Update and upload Rspack development test manifest (push) Has been cancelled
Update Rspack test manifest / Update and upload Rspack production test manifest (push) Has been cancelled
Upload bundler test manifests to areweturboyet.com / Upload test results (push) Has been cancelled
Update React / create-pull-request (push) Has been cancelled
test-e2e-project-reset-cron / reset-test-project (push) Has been cancelled
Notify about the top 15 issues/PRs/feature requests (most reacted) in the last 90 days / run (push) Has been cancelled

This commit is contained in:
Arian Tron
2026-03-10 19:37:31 +03:30
commit 61f56f997c
27684 changed files with 2784175 additions and 0 deletions

View File

@@ -0,0 +1,5 @@
'use client'
export default function bar() {
return 'bar.client'
}

View File

@@ -0,0 +1,10 @@
import Foo from './foo'
export default function Bar() {
return (
<div id="bar">
{`bar.server.js: `}
<Foo />
</div>
)
}

View File

@@ -0,0 +1,5 @@
'use client'
exports.Cjs = function Cjs() {
return 'cjs-client'
}

View File

@@ -0,0 +1,3 @@
exports.Cjs = function Cjs() {
return 'cjs-shared'
}

View File

@@ -0,0 +1,7 @@
'use client'
export function Named() {
return 'named.client'
}
export default () => 'default-export-arrow.client'

View File

@@ -0,0 +1,9 @@
'use client'
import { useState } from 'react'
export default function Client() {
// To ensure that this component is rendered as a client component, we use a
// state here.
return useState('client_component')[0]
}

View File

@@ -0,0 +1,3 @@
'use client'
export * from './one'

View File

@@ -0,0 +1,6 @@
export function One() {
return 'one'
}
export * from './two'
export { Two as TwoAliased } from './two'

View File

@@ -0,0 +1,3 @@
export function Two() {
return 'two'
}

View File

@@ -0,0 +1,5 @@
'use client'
export default function foo() {
return 'foo.client'
}

View File

@@ -0,0 +1,23 @@
import Link from 'next/link'
export default function Nav() {
return (
<>
<div>
<Link href={'/next-api/link'} id="goto-next-link">
next link
</Link>
</div>
<div>
<Link href={'/streaming-rsc'} id="goto-streaming-rsc">
streaming rsc
</Link>
</div>
<div>
<Link href={'/root'} id="goto-home">
home
</Link>
</div>
</>
)
}

View File

@@ -0,0 +1,22 @@
'use client'
import { useState, useEffect } from 'react'
export default function Counter() {
const [count, setCount] = useState(0)
useEffect(() => {
// When this component is hydrated, there might be other parts still pending
// on streaming. So we test the interactivity of the document before it's
// fully loaded.
const counter = document.querySelector('button')
const suspense = document.querySelector('.suspense')
counter.click()
setTimeout(() => {
window.partial_hydration_suspense_result = suspense.textContent
window.partial_hydration_counter_result = counter.textContent
}, 0)
}, [])
return <button onClick={() => setCount(count + 1)}>count: {count}</button>
}

View File

@@ -0,0 +1,7 @@
'use client'
import styles from './style.module.css'
export default function RedText(props) {
return <div {...props} className={styles.text} />
}

View File

@@ -0,0 +1,3 @@
.text {
color: red;
}

View File

@@ -0,0 +1,5 @@
'use client'
import Shared from './shared'
export default Shared

View File

@@ -0,0 +1,10 @@
const a = 'a'
const b = 'b'
const _c = 'c'
const _d = 'd'
const _e = 'e'
const _eArr = [_e]
export const c = _c
export { a, b }
export { _d as d, _eArr as e }

View File

@@ -0,0 +1,21 @@
import React from 'react'
import Client from './client'
const random = ~~(Math.random() * 10000)
export default function Shared() {
let isServerComponent
try {
React.useState()
isServerComponent = false
} catch (e) {
isServerComponent = true
}
return (
<>
<Client />,{' '}
{(isServerComponent ? 'shared:server' : 'shared:client') + ':' + random}
</>
)
}