docs/plans/2026-03-11-www-typecheck-regression.md
Find which local workspace/config change caused apps/www registry files to start surfacing type errors that did not appear before.
apps/www typecheck failureapps/www tsconfig / package resolution / workspace setup changesapps/www errors: implicit-any diagnostics in src/registry/components/editor/plugins/ai-kit.tsx, copilot-kit.tsx, src/registry/ui/ai-menu.tsx, toc-node.tsx, and toc-node-static.tsx.tsconfig.json source path aliases are not the primary cause. A temp app tsconfig that removed inherited @platejs/*/platejs source aliases still produced the same errors.apps/www now consumes local workspace packages via workspace:^ entries in apps/www/package.json.packages/ai/dist/react/index.d.ts, AIPlugin and AIChatPlugin are declared as any. In packages/toc/dist/react/index.d.ts, useTocElementState() returns editor: any and headingList: any. Those any declarations erase contextual typing in the registry callbacks and trigger noImplicitAny in app code.apps/www regression is actually a package declaration quality regression surfaced by the workspace setup.pnpm --dir apps/www typecheck: reproduced failurepnpm --dir apps/www exec tsc --noEmit -p tsconfig.debug-node_modules.json: same failure even without inherited root package source aliasespackages/ai/dist/react/index.d.ts and packages/toc/dist/react/index.d.ts: confirmed exported any types at the relevant APIs.d.ts files in packages leak straight into app typecheck.