feat!: framework mode — structure in config and conventions, JSX only for rendering (RFC #63) - #67
Conversation
…conventional skills/*/SKILL.md uncovered (RFC #63)
…KILL.md at build via the minimal markdown renderer (RFC #63)
…rectory convention (RFC #63)
…ation; createRscMcpServer/runRscCli consume it; migrate audiobook-curator to framework mode (RFC #63)
…McpServer/McpApp/Operation elements and defineRscAgentBundle are gone; JSX renders, config and conventions structure (RFC #63)
…ference, changesets (RFC #63)
🦋 Changeset detectedLatest commit: 9fe29ee The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
commit: |
…AB30xx family (RFC #63)
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d5e4b60be8
ℹ️ About Codex in GitHub
Your team has set up Codex to 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 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "@types/ws": "8.18.1" | ||
| "@types/react": "19.2.18", | ||
| "@types/ws": "8.18.1", | ||
| "react": "19.2.8" |
There was a problem hiding this comment.
Ship the JSX runtime required by rendered skills
When a consumer follows the documented SKILL.tsx example without independently installing React, Jiti's automatic JSX transform imports react/jsx-runtime, but published packages do not install their devDependencies. This makes every ordinary JSX-based rendered skill fail to load with AB3003; React must be a runtime/peer dependency with an explicit installation contract, or the compiler must provide its own JSX runtime.
Useful? React with 👍 / 👎.
| const body = text.endsWith('\n') ? text.slice(0, -1) : text; | ||
| return `\`\`\`${language}\n${body}\n\`\`\``; |
There was a problem hiding this comment.
Size Markdown fences to preserve embedded backticks
When a rendered <pre><code> block contains a triple-backtick sequence—common when a skill documents Markdown—the fixed three-backtick delimiter is closed by the content, so the generated SKILL.md treats the remainder as ordinary Markdown and changes the skill's instructions. Choose a fence longer than any backtick run in the body, or use a safe alternate fence.
Useful? React with 👍 / 👎.
…n, link the model doc, restore the MCP Apps guidance (#69) Wave B of the examples refresh, unblocked by #67. B1: verified the audiobook-curator framework-mode migration landed as designed (inspect reports diagnostics: [] with conventional provenance on the MCP entry, Skill, bin, and lib; structure declared in config). Swept one leftover — the migrated tests/application.test.tsx kept its extension after losing its last JSX, so it is now .ts, matching #67's own src/application.tsx rename. B2: skills-starter's README links docs/framework-mode.md where it teaches the skills-directory convention. B3: the reframe itself already landed in #67, which replaced the structural-JSX section and deleted tests/plugin-app.test.ts wholesale; no rsc-runtime test teaches a removed element. What #67 missed was a deletion: it dropped the <McpApp> paragraph instead of restating it, leaving the README teaching _meta.ui.resourceUri widget binding with nothing saying where the widget is declared. Restored in config-mode terms, plus a link to the framework-mode doc. Docs and one rename only; no behavior change, so no changeset.
Summary
Implements RFC #63 end to end, greenfield (no compatibility hedges):
AB4734) — when explicitskillsconfig leaves a conventionalskills/<name>/SKILL.mduncovered, validation reports an info nudge naming the shadowed skill. Config wins, conventions fill — same precedence one-liner as RFC RFC: agent-bundle owns the build — one config, framework entry conventions #50's entry conventions.skills/<name>/SKILL.tsx(or.ts) default-exports a component and exportsfrontmatter; the build compiles the element tree to Markdown through a dependency-free renderer (documented element subset; anything outside it is a named error, never a silent approximation) and emits theSKILL.mdas a generated write entry per target. A hand-authoredSKILL.mdalways wins (AB4735).defineRscApplication— flat, JSX-free runtime declaration:{ name, version, description?, operations }.runRscCliandcreateRscMcpServerconsume it; the server name selects operations, structure stays in config.AgentBundle,Skill,Script,McpServer,McpApp,Operation,defineRscAgentBundle, andRscAgentBundleApplicationare gone from@agent-bundle/rsc-runtime, along with itsagent-bundlepeer dependency. JSX renders (Mcp.*/Hook.*, rendered skills); config and conventions structure.agent-bundle.config.tsdeclares the structure (skill ships by convention with no declaration; MCP server uses the conventionalsrc/mcp/curator.tsentry),src/application.tsis JSX-free composition, andapplication.tsx/mcp-server.tsare deleted. Zero diagnostics; behavior preserved (same skill markdown, same 13 CLI commands and 15 MCP tools).minimalnow teaches the skills-directory convention (noskillsfield);mcp-serverandcli-toolalready taught the conventional entries. All three validate with zero diagnostics via the packed-pool e2e.docs/framework-mode.md(newcomer path: one directory convention, one flat config, "JSX = rendering"),AB4734/AB4735indocs/diagnostics.md, cross-links from the root README anddocs/entry-conventions.md. Changesets: minor for both packages, prose states the removals plainly.Every commit keeps the repo gate green; the removal commit is last.
movie-library(separate repo, pinned previews) migrates when it bumps: its five-server tree becomes fivemcp.serversconfig entries + conventionalsrc/mcp/<id>.tsfiles, and its app tree becomesdefineRscApplication.Gate
test:packedincl. scaffolder packed-pool e2e (real tarballs, per-template check): 22 passedCloses #63.