refactor(api): productize public API surface to 18 flat export paths - #264
Merged
Merged
Conversation
Reduce npm-visible exports from 62 paths to 18 product-oriented paths. Every export is now justified as user-facing; internal infrastructure is invisible to npm consumers. New barrels: chat, markdown, mdx, fs Slimmed barrels: agent, tool, workflow, prompt, resource, mcp, middleware, oauth, provider, react, config, platform, cache, build, rendering Root barrel: server core + config + routing + data + validation - Convert all star-exports to selective re-exports - Move CLI-only paths from exports to imports (dnt resolves at build) - Create src/chat (UI components + hooks), src/markdown (runtime rendering), src/mdx (MDX provider), src/fs (filesystem + path utils) - Slim workflow barrel to DSL + types + backends + client + hooks - Fix 29 type errors in newly typechecked entrypoints - Update all templates, examples, and browser import maps - Add docs/api.md with full public API documentation - 1078 tests passing, 0 type errors across 36 entrypoints
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 862890760c
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Without this, requests for /_veryfront/lib/mdx.js 404 in self-hosted module resolution mode.
kojiwakayama
force-pushed
the
refactor-api
branch
from
February 7, 2026 21:16
bf0f43e to
c1db7e9
Compare
- Run deno fmt on workflow/index.ts, html/utils.ts, agent-card.tsx - Inline Link component in router barrel (avoids relative import in embedded framework sources that breaks compiled binary SSR resolution) - Delete components/Link.tsx (zero consumers), remove from components barrel - Link now lives exclusively in veryfront/router
kojiwakayama
force-pushed
the
refactor-api
branch
from
February 7, 2026 21:22
c1db7e9 to
84333f8
Compare
kwakayama
added a commit
that referenced
this pull request
Feb 9, 2026
The API surface refactor (#264) reduced exports to 18 flat paths, none of which transitively import react-dom/client. dnt fails when a mapping is specified but no entry point source file references it.
2 tasks done
kwakayama
added a commit
that referenced
this pull request
Feb 9, 2026
The API surface refactor (#264) reduced exports to 18 flat paths, none of which transitively import react-dom/client. dnt fails when a mapping is specified but no entry point source file references it.
ariskemper
pushed a commit
that referenced
this pull request
Feb 9, 2026
…264) * refactor(api): productize public API surface to 18 flat export paths Reduce npm-visible exports from 62 paths to 18 product-oriented paths. Every export is now justified as user-facing; internal infrastructure is invisible to npm consumers. New barrels: chat, markdown, mdx, fs Slimmed barrels: agent, tool, workflow, prompt, resource, mcp, middleware, oauth, provider, react, config, platform, cache, build, rendering Root barrel: server core + config + routing + data + validation - Convert all star-exports to selective re-exports - Move CLI-only paths from exports to imports (dnt resolves at build) - Create src/chat (UI components + hooks), src/markdown (runtime rendering), src/mdx (MDX provider), src/fs (filesystem + path utils) - Slim workflow barrel to DSL + types + backends + client + hooks - Fix 29 type errors in newly typechecked entrypoints - Update all templates, examples, and browser import maps - Add docs/api.md with full public API documentation - 1078 tests passing, 0 type errors across 36 entrypoints * fix(server): add mdx.js to allowed self-hosted lib modules Without this, requests for /_veryfront/lib/mdx.js 404 in self-hosted module resolution mode. * fix(ci): resolve format and binary E2E test failures - Run deno fmt on workflow/index.ts, html/utils.ts, agent-card.tsx - Inline Link component in router barrel (avoids relative import in embedded framework sources that breaks compiled binary SSR resolution) - Delete components/Link.tsx (zero consumers), remove from components barrel - Link now lives exclusively in veryfront/router
ariskemper
pushed a commit
that referenced
this pull request
Feb 9, 2026
The API surface refactor (#264) reduced exports to 18 flat paths, none of which transitively import react-dom/client. dnt fails when a mapping is specified but no entry point source file references it.
kojiwakayama
added a commit
that referenced
this pull request
Aug 17, 2026
Production HTML selects the single content-addressed hydration runtime from the rendered release's configured build output and uses it for preload and execution across component, script-page, and snippet shells. Canonical enriched release identity now survives the complete snippet path, and public release-aware shell calls fail closed unless a runtime was selected. Constraint: Pre-change immutable releases cannot gain new manifest metadata, so selection must discover the runtime already present in the release artifact set. Rejected: Serve the current runtime under a release URL | recreates the cross-artifact compatibility skew from incident #264 Rejected: Assume dist is the build output | build.outDir is a supported project contract Confidence: high Scope-risk: moderate Reversibility: clean Directive: Retire a release hydration runtime only with its release; never redirect its hashed path to newer bytes. Tested: Full integration 302 tests/2840 steps; focused 10 suites/175 steps; aged-release Chromium 2 steps; isolated NavigationMenu 9 steps; production/test typecheck; lint/fmt; dependency/module boundaries; anti-slop; guide/public docs; pinned Deno 2.7.7 API docs Not-tested: A wholly green local unit aggregate; 3919 tests/29929 steps passed before the known NavigationMenu timer-leak flake, whose isolated rerun passed. Exact-head GitHub CI is required before merge. Related: veryfront/veryfront-issue-inbox#277
kojiwakayama
added a commit
that referenced
this pull request
Aug 17, 2026
Production HTML selects the single content-addressed hydration runtime from the rendered release build output and uses it for preload and execution across component, script-page, and snippet shells. Canonical enriched release identity now survives the complete snippet path, while standalone source serving falls back to the current runtime only when its synthetic release has no build artifact directory. Constraint: Pre-change immutable releases cannot gain new manifest metadata, so selection must discover the runtime already present in the release artifact set. Rejected: Serve the current runtime under a release URL | recreates the cross-artifact compatibility skew from incident #264 Rejected: Treat every production release identity as artifact-backed | compiled standalone source serving uses the synthetic standalone-dev identity without a build output directory Confidence: high Scope-risk: moderate Reversibility: clean Directive: Retire a release hydration runtime only with its release; never redirect its hashed path to newer bytes. Tested: Fresh compiled-binary E2E 1 test/65 steps; focused release-render matrix 18 tests/255 steps; aged-release Chromium 2 steps; full integration 302 tests/2840 steps; production/test typecheck; lint/fmt; dependency/module boundaries; anti-slop; guide/public docs; pinned Deno 2.7.7 API docs Not-tested: A wholly green local unit aggregate; 3919 tests/29929 steps passed before the known NavigationMenu timer-leak flake, whose isolated rerun passed. Exact-head GitHub CI is required before merge. Related: veryfront/veryfront-issue-inbox#277
kojiwakayama
added a commit
that referenced
this pull request
Aug 17, 2026
Production HTML selects the single content-addressed hydration runtime from the rendered release build output and uses it for preload and execution across component, script-page, and snippet shells. Canonical enriched release identity now survives the complete snippet path, while standalone source serving falls back to the current runtime only when its synthetic release has no build artifact directory. Constraint: Pre-change immutable releases cannot gain new manifest metadata, so selection must discover the runtime already present in the release artifact set. Rejected: Serve the current runtime under a release URL | recreates the cross-artifact compatibility skew from incident #264 Rejected: Treat every production release identity as artifact-backed | compiled standalone source serving uses the synthetic standalone-dev identity without a build output directory Confidence: high Scope-risk: moderate Reversibility: clean Directive: Retire a release hydration runtime only with its release; never redirect its hashed path to newer bytes. Tested: Fresh compiled-binary E2E 1 test/65 steps; focused release-render matrix 18 tests/255 steps; aged-release Chromium 2 steps; full integration 302 tests/2840 steps; production/test typecheck; lint/fmt; dependency/module boundaries; anti-slop; guide/public docs; pinned Deno 2.7.7 API docs Not-tested: A wholly green local unit aggregate; 3919 tests/29929 steps passed before the known NavigationMenu timer-leak flake, whose isolated rerun passed. Exact-head GitHub CI is required before merge. Related: veryfront/veryfront-issue-inbox#277
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
veryfront/chat,veryfront/markdown,veryfront/mdx,veryfront/fsexportstoimports(invisible to npm, dnt resolves at build)The 18 Paths
veryfrontveryfront/head<Head>componentveryfront/router<Link>veryfront/contextveryfront/fontsveryfront/chatveryfront/markdownveryfront/mdxveryfront/agentveryfront/toolveryfront/workflowveryfront/promptveryfront/resourceveryfront/mcpveryfront/middlewareveryfront/oauthveryfront/providerveryfront/fsKey Changes
AgentMessagealias (Message deprecated), kept composition utilsreact/components/ai) + hooks (fromagent/react)Test plan
deno task typecheck— 0 errors across 36 entrypointsdeno task lint— cleandeno task test— 1078 passed, 0 faileddeno check src/{chat,markdown,mdx,fs,oauth,agent,tool,workflow,prompt,resource,mcp,provider,middleware}/index.ts)