mirror of
https://github.com/CopilotKit/CopilotKit.git
synced 2026-09-14 16:26:20 +08:00
4cbc2ca380
(a) patch-xhr: replace the previous pass-through (which always forced 5
args with async defaulting to true) with a typed rest-tuple + branched
.call dispatch that preserves the caller's exact 2-arg-or-5-arg call
shape. Two narrowed function-type assignments — one per open overload —
sit at the boundary and let TypeScript route each .call to the correct
overload directly, without casts. Also captures the originals into
non-null consts so the patched closures don't need null assertions, and
drops the now-redundant explicit `this: CapturingXhr` (the prototype-
assignment context provides it implicitly). Together this clears the
type errors that the original 'as any' had been hiding.
(b) docs: add a note to the reference page that HTML <form method="POST">
submissions are not captured (they leave the page via browser navigation,
not patched JS APIs) with the workaround.
Also tidies up the use-auto-capture-user-actions test that exercised
config change reactivity — its Props type was being inferred as
{ deny: undefined } from initialProps, breaking rerender — and the
patch-sendbeacon test's delete operator on navigator.sendBeacon
(uses a narrower partial-shape cast so the delete is well-typed).
Net result: zero as-any, zero @ts-ignore, zero @ts-expect-error in the
shipped auto-capture module; strict tsc -p tsconfig.json on react-core
reports zero new errors anywhere in the module; lint 0/0; full
@copilotkit/react-core suite 1289 tests / 103 files, stable across three
consecutive --skip-nx-cache runs.
fumadocs-test
This is a Next.js application generated with Create Fumadocs.
Run development server:
npm run dev
# or
pnpm dev
# or
yarn dev
Open http://localhost:3000 with your browser to see the result.
Learn More
To learn more about Next.js and Fumadocs, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
- Fumadocs - learn about Fumadocs
Vercel Deployment with Git LFS
Docs assets are tracked with Git LFS. To ensure production builds always receive
real asset bytes (not pointer files), deploy docs through GitHub Actions using
.github/workflows/deploy_docs_vercel.yml.
Required GitHub repository secrets:
VERCEL_TOKENVERCEL_ORG_IDVERCEL_PROJECT_ID_DOCS
PR previews:
.github/workflows/deploy_docs_vercel_preview.ymldeploys docs previews for non-fork pull requests.- The workflow posts/updates a sticky PR comment with a clickable
Open Docs Previewlink.
Recommended Vercel project setting:
- Disable automatic Git-based deployments for the docs project and let the GitHub Actions workflow handle production deploys.