{"_id":"@aphrody/next-playwright","_rev":"8-f47596909aa4aabf5d3d6e50ecdfdb48","name":"@aphrody/next-playwright","dist-tags":{"latest":"0.2.5"},"versions":{"0.1.1":{"name":"@aphrody/next-playwright","version":"0.1.1","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.1.1","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"dist":{"shasum":"878c72a317e59c86da97099e73a8401d68598013","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.1.1.tgz","fileCount":6,"integrity":"sha512-ESqsE2ygHkQ0IMD/7hQWfOCzrgl5Uyt6Lq1ac4P47O7BC4Up6HLgfPnfhgPiirZh0PqBRUrEe+Ev7mKb0q3Hvg==","signatures":[{"sig":"MEQCIGJkHkV9RBAf1EaJ6wUqYPXqOT2ZiuRYsPdU/ob+BFx/AiB6rhUKDxTlKnG2v7xBFOKGcrOVtSqJcg9kZ5i499czhw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18816},"main":"./src/index.ts","type":"module","types":"./src/index.ts","exports":{".":"./src/index.ts"},"gitHead":"7409bb65fef1c022208151a69304547bf9a4e516","scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_npmVersion":"9.2.0","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.1.1"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.1.1_1780527320264_0.8532560912289922","host":"s3://npm-registry-packages-npm-production"}},"0.1.2":{"name":"@aphrody/next-playwright","version":"0.1.2","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.1.2","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"dist":{"shasum":"681e9043eea48a4ff8d6b0efc52fb0afaa415161","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.1.2.tgz","fileCount":7,"integrity":"sha512-sJOAwfJw25WYwmpHVpV3Th3KViUUoys3QkUQ9CVLfvqzfywMUxeOsWEYPfW+pdL5bSfYi/Sk3oF8x4tNt1HyAQ==","signatures":[{"sig":"MEUCIAwZT3O1vjIg5UXbcM763xM2Y/YRx8qMjwEOWmqIaOgcAiEA9zIRlNKNfxJB/q4he+vj5fMWcdToRDt4+s+sMI5Gz/A=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":23704},"main":"./src/index.ts","type":"module","types":"./src/index.ts","shasum":"681e9043eea48a4ff8d6b0efc52fb0afaa415161","exports":{".":"./src/index.ts"},"scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_integrity":"sha512-sJOAwfJw25WYwmpHVpV3Th3KViUUoys3QkUQ9CVLfvqzfywMUxeOsWEYPfW+pdL5bSfYi/Sk3oF8x4tNt1HyAQ==","_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.1.1"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.1.2_1780586742841_0.5742282015606737","host":"s3://npm-registry-packages-npm-production"}},"0.1.4":{"name":"@aphrody/next-playwright","version":"0.1.4","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.1.4","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"dist":{"shasum":"be6e02aad5667291827164739e8646664db3ed72","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.1.4.tgz","fileCount":7,"integrity":"sha512-qGvOG4ppAMHhIIyzSRPP1g2ql1IMHBul+8CoXuW637dNJs9dXPZq/9NleGq/L/RcP5eTPrBiW9Zz/dK2Hk7M1A==","signatures":[{"sig":"MEYCIQDB88rpXPZlGTuS6Fqmy1dQXHNwUgeT1F2qR6z1nt+HTQIhANT/NWVgG24bzbFb2i9Zku7QUoye7AsWsyj/t9pfGxxg","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":23704},"main":"./src/index.ts","type":"module","types":"./src/index.ts","shasum":"be6e02aad5667291827164739e8646664db3ed72","exports":{".":"./src/index.ts"},"scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_integrity":"sha512-qGvOG4ppAMHhIIyzSRPP1g2ql1IMHBul+8CoXuW637dNJs9dXPZq/9NleGq/L/RcP5eTPrBiW9Zz/dK2Hk7M1A==","_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.1.3"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.1.4_1786525419573_0.07374636796112011","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@aphrody/next-playwright","version":"0.2.0","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.2.0","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"dist":{"shasum":"7ee40d91f201a65a25ce3f1039136de03ae87fed","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.2.0.tgz","fileCount":5,"integrity":"sha512-99Lj6DK9Ua9dzl00BZc0S/Rn3ovwu7b+9Zz9IzXGRe0G5Bq49GUMKvl+gYabiL5oHdxi1DB561Y9TxICQ+3WhA==","signatures":[{"sig":"MEUCIQCLGLU6niv/GCoxAYXPQ8db1dCYXeBOYIC9O1fAmX3HEQIgbWiIBNcg30eVsmW/mW8+EEsmwgZGvENcLjTb3rhc/NM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18476},"main":"./src/index.ts","type":"module","types":"./src/index.ts","shasum":"7ee40d91f201a65a25ce3f1039136de03ae87fed","engines":{"bun":">=1.3.14"},"exports":{".":"./src/index.ts"},"scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_integrity":"sha512-99Lj6DK9Ua9dzl00BZc0S/Rn3ovwu7b+9Zz9IzXGRe0G5Bq49GUMKvl+gYabiL5oHdxi1DB561Y9TxICQ+3WhA==","_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.1.3"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.2.0_1788431561924_0.047686053898295944","host":"s3://npm-registry-packages-npm-production"}},"0.2.1":{"name":"@aphrody/next-playwright","version":"0.2.1","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.2.1","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"dist":{"shasum":"53ce7eb31e8e91423cd205e571dc5345f90c6bc4","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.2.1.tgz","fileCount":5,"integrity":"sha512-gtXbyursRWhjkRgS/4cJq0QWCuXSZAS2AyUpNjCE7JBV+Z8FoInsbv6gLn78iq9AuTLR09JnkBHRcpjLWrOvNQ==","signatures":[{"sig":"MEUCIAxpss6o1rDsz7G1xrrvaeEkZL2M29QU4SSsdFJEi7IZAiEAwqM7tD5bnwyfYJYgMrJ4C1W6NNa12uFJIEIq5wh2qHo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18476},"main":"./src/index.ts","type":"module","types":"./src/index.ts","shasum":"53ce7eb31e8e91423cd205e571dc5345f90c6bc4","engines":{"bun":">=1.3.14"},"exports":{".":"./src/index.ts"},"scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_integrity":"sha512-gtXbyursRWhjkRgS/4cJq0QWCuXSZAS2AyUpNjCE7JBV+Z8FoInsbv6gLn78iq9AuTLR09JnkBHRcpjLWrOvNQ==","_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.2.1"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.2.1_1788681517195_0.2880814633684903","host":"s3://npm-registry-packages-npm-production"}},"0.2.3":{"name":"@aphrody/next-playwright","version":"0.2.3","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.2.3","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"bugs":{"url":"https://github.com/aphrody-code/next-playwright/issues"},"dist":{"shasum":"c2bfb6878653ebe03266e25ac663521516835923","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.2.3.tgz","fileCount":5,"integrity":"sha512-lcqzsHOUVdmr2TvVXYz6Ji22Spm4L98hMT8TEfAFGtBIq5jaNFwtF9Y38J8XRCNeuPgH7n+/Pygn617odS9eow==","signatures":[{"sig":"MEUCIQCklkRLzdUwK7tVekklrrEW1xKOdaMUP/oRH+qpP/9Z6wIgVXVLda3KrmaK/lgi2ncF/I8TapnWnFyFdPngWh7F0Y8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":19119},"main":"./src/index.ts","type":"module","types":"./src/index.ts","shasum":"c2bfb6878653ebe03266e25ac663521516835923","engines":{"bun":">=1.3.14"},"exports":{".":"./src/index.ts"},"scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"_integrity":"sha512-lcqzsHOUVdmr2TvVXYz6Ji22Spm4L98hMT8TEfAFGtBIq5jaNFwtF9Y38J8XRCNeuPgH7n+/Pygn617odS9eow==","repository":{"url":"https://github.com/aphrody-code/next-playwright.git","type":"git"},"_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"26.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.2.3"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.2.3_1788770726786_0.7141045550068998","host":"s3://npm-registry-packages-npm-production"}},"0.2.4":{"name":"@aphrody/next-playwright","version":"0.2.4","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"license":"Apache-2.0","_id":"@aphrody/next-playwright@0.2.4","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"homepage":"https://github.com/aphrody-code/next-playwright#readme","bugs":{"url":"https://github.com/aphrody-code/next-playwright/issues"},"dist":{"shasum":"50a221445da27bc1aae7b313c03f72cf81a3ae59","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.2.4.tgz","fileCount":5,"integrity":"sha512-DvemJ5c9rXB12OqarpnM9YVDQOokvKiN7T8w94b1a650g6nEUjSRgCmeX/BOm0jNth48GNGmR7vhW78YrMg04g==","signatures":[{"sig":"MEYCIQCfEz2exAjeAQMM1PJ7VlsMJ4U65V7WTKRxlofBWcgWYQIhAOK1OVU2rAXzwlTsKr8CQuIrFJMLSSvwtVFE4bh6sBhM","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":18671},"main":"./src/index.ts","type":"module","types":"./src/index.ts","engines":{"bun":">=1.3.14"},"exports":{".":"./src/index.ts"},"gitHead":"b586f114f810d55b9e1b2aea63c0cd1378f76a8c","scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"repository":{"url":"git+https://github.com/aphrody-code/next-playwright.git","type":"git"},"_npmVersion":"9.2.0","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.2.3"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/next-playwright_0.2.4_1789022215447_0.11933002852064734","host":"s3://npm-registry-packages-npm-production"}},"0.2.5":{"_id":"@aphrody/next-playwright@0.2.5","bugs":{"url":"https://github.com/aphrody-code/next-playwright/issues"},"dist":{"shasum":"34a669ed897a67ffdb09280d5ea7f5450e98c3eb","tarball":"https://registry.npmjs.org/@aphrody/next-playwright/-/next-playwright-0.2.5.tgz","fileCount":5,"integrity":"sha512-8FbVE/Jm0B/JruwjTunvWdYbbo0SG9WZPXKsvoQRm2vZsY95QiCoRfditMvlt6LFoyOMXIukiuqkyRoChln0Yg==","signatures":[{"sig":"MEUCIET0NWKUR1XE2mGZ/FONFzETQyxgXYQGWrUf+Rlx/52lAiEAiMCjQrTKNdjj/fx4bnsnh9H5nKb0uoRm/f20EgiRpoA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIBl+GTqfzUPshjEe/G4ry4BDqmaMVGUCod4HX+HN633FAiEA0PiKPXVaO2Ct3i4o49KVo5FRpkGT6i1eAgIisF5+fsI="}],"unpackedSize":18667},"main":"./src/index.ts","name":"@aphrody/next-playwright","type":"module","types":"./src/index.ts","shasum":"34a669ed897a67ffdb09280d5ea7f5450e98c3eb","engines":{"bun":">=1.4.2"},"exports":{".":"./src/index.ts"},"license":"Apache-2.0","scripts":{"lint":"oxlint","test":"bun test test/","typecheck":"tsc --noEmit"},"version":"0.2.5","_npmUser":{"name":"yohan971","email":"yohanpierre@live.fr"},"keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"_integrity":"sha512-8FbVE/Jm0B/JruwjTunvWdYbbo0SG9WZPXKsvoQRm2vZsY95QiCoRfditMvlt6LFoyOMXIukiuqkyRoChln0Yg==","repository":{"url":"https://github.com/aphrody-code/next-playwright.git","type":"git"},"_npmVersion":"10.8.3","description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","directories":{},"maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"_nodeVersion":"24.3.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"^1.3.14","typescript":"^6.0.3"},"peerDependencies":{"@aphrody/bxc-test":"^0.2.5"},"peerDependenciesMeta":{"@aphrody/bxc-test":{"optional":true}},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/next-playwright_0.2.5_1789648737768_0.8257525868216726"}}},"time":{"created":"2026-06-03T22:55:20.071Z","modified":"2026-09-17T12:38:58.309Z","0.1.1":"2026-06-03T22:55:20.406Z","0.1.2":"2026-06-04T15:25:43.003Z","0.1.4":"2026-08-12T09:03:39.723Z","0.2.0":"2026-09-03T10:32:42.065Z","0.2.1":"2026-09-06T07:58:37.323Z","0.2.3":"2026-09-07T08:45:26.904Z","0.2.4":"2026-09-10T06:36:55.591Z","0.2.5":"2026-09-17T12:38:57.851Z"},"bugs":{"url":"https://github.com/aphrody-code/next-playwright/issues"},"license":"Apache-2.0","keywords":["aphrody","bxc","bun","next","nextjs","playwright","instant","navigation-testing","cache-components","cdp"],"repository":{"url":"https://github.com/aphrody-code/next-playwright.git","type":"git"},"description":"Next.js instant() navigation-testing primitive (port of @next/playwright) for bxc's CDP-backed test runner. Drives the next-instant-navigation-testing cookie protocol over Network.setCookies/getCookies/deleteCookies — no @playwright/test runtime dependenc","maintainers":[{"name":"yohan971","email":"yohanpierre@live.fr"}],"readme":"<!-- SPDX-License-Identifier: Apache-2.0 -->\n\n# @aphrody/next-playwright\n\nA bxc port of Next.js's [`@next/playwright`](https://github.com/vercel/next.js/tree/canary/packages/next-playwright) — the `instant()` navigation-testing primitive — built on [`@aphrody/bxc-test`](../test) and bxc's native CDP layer. **No `@playwright/test` runtime dependency.**\n\n`instant(page, fn)` runs `fn` while the `next-instant-navigation-testing` cookie is set. Inside the scope, a Next.js app with **Cache Components** serves only cached/prefetched content and defers dynamic data until the cookie is cleared — letting a test assert the instant (prefetched) shell deterministically.\n\n## Why a port\n\n`@next/playwright` talks to a Playwright `BrowserContext` (`page.context().addCookies / cookies / clearCookies`). bxc drives Chrome — and its fully-offline `static` DOM — over **CDP**, not Playwright. This package keeps the load-bearing half **byte-for-byte** and swaps only the substrate:\n\n| Piece | Treatment |\n| --- | --- |\n| Cookie name `next-instant-navigation-testing` | **copied verbatim** — the contract Next.js reads (`navigation-testing-lock.ts`). Renaming it breaks the protocol. |\n| Cookie value `JSON.stringify([0, \"p\"+Math.random()])`, `domain`/`path` scoping | copied verbatim |\n| Nesting guard (read `context().cookies()`, throw if already set) | copied verbatim |\n| `resolveURL` + the descriptive `about:blank` error | copied verbatim |\n| acquire → `fn()` → release-in-`finally` semantics | copied verbatim |\n| `step()` (was `@playwright/test` `test.step`) | **reimplemented** — a pluggable bxc reporter, defaults to direct execution |\n| cookie ops (was Playwright `BrowserContext`) | **reimplemented** — `CdpCookieContext` over `Network.setCookies` / `getCookies` / `deleteCookies` |\n\n## Usage\n\n```ts\nimport { test, expect } from \"@aphrody/bxc-test\";\nimport { instant, adaptPage } from \"@aphrody/next-playwright\";\n\ntest(\"instant navigation to /dashboard\", async ({ page }) => {\n  await page.goto(\"http://localhost:3000/\");\n  await instant(adaptPage(page), async () => {\n    await page.getByRole(\"link\", { name: \"Dashboard\" }).click();\n    // Only the prefetched shell is rendered inside the scope:\n    await expect(page.getByRole(\"heading\")).toHaveText(\"Dashboard\");\n  });\n});\n```\n\n`adaptPage(testPage)` bridges a bxc `TestPage` (or any page exposing `_cdp` / `_send` and `url()`) to the structural `PlaywrightPage` that `instant()` expects, routing the cookie context through CDP.\n\nA real Playwright `Page` already satisfies the structural `PlaywrightPage` type, so `instant(page, fn)` works against Playwright unchanged — the package is runner-agnostic by design.\n\n### Fresh page (no navigation yet)\n\n```ts\nawait instant(adaptPage(page), async () => {\n  await page.goto(\"http://localhost:3000\");\n  // ...\n}, { baseURL: \"http://localhost:3000\" });\n```\n\n## API\n\n- `instant<T>(page, fn, options?) => Promise<T>` — acquire/release the lock around `fn`. `options.baseURL` scopes the cookie before the first navigation.\n- `adaptPage(bxcPage) => PlaywrightPage` — wrap a bxc page as the structural target.\n- `CdpCookieContext` — the `addCookies` / `cookies` / `clearCookies` adapter over CDP, usable standalone.\n- `INSTANT_COOKIE` — the cookie-name constant (`next-instant-navigation-testing`).\n- `setStepReporter(fn | null)` — install a custom step reporter (trace/label sink).\n- Types: `PlaywrightPage`, `PlaywrightBrowserContext`, `BxcPageLike`, `CdpSend`, `PwCookie`, `PwCookieParam`, `Step`.\n\n## Relationship to `src/next`\n\nbxc core also ships `@aphrody/bxc/next` (`src/next/`) — a bxc-native, page-direct variant of `instant()` (the page itself exposes `addCookies`/`clearCookies`; nesting is guarded by an in-process flight lock) plus `withPlaywrightPage()`. This package is the **faithful, publishable mirror of vercel's `packages/next-playwright`** (structural `context()` shape, cookie-read nesting guard), layered on the `@aphrody/bxc-test` runner. Use the core module for quick bxc scripts; use this package when you want the exact `@next/playwright` surface in a `bun test` suite.\n\n## Scope\n\nThis is **only** the `instant()` primitive — exactly like upstream. No dev/build/start harness, no fixtures. The Next.js consumer side (serving cached content) lives in the framework and requires Cache Components; in production builds it is gated behind `experimental.exposeTestingApiInProductionBuild`.\n\n## License\n\nApache-2.0. Ports the MIT-licensed `@next/playwright` cookie protocol (constant + value shape); see header notes.\n","readmeFilename":"README.md"}