refactor(devframe): namespace adapters and invert client dep from kit#299
Merged
antfu merged 2 commits intoantfu/devframefrom Apr 23, 2026
Merged
refactor(devframe): namespace adapters and invert client dep from kit#299antfu merged 2 commits intoantfu/devframefrom
antfu merged 2 commits intoantfu/devframefrom
Conversation
Move the six adapters (cli/build/spa/vite/kit/embedded) into `devframe/adapters/*` so they're clearly grouped and no longer share the top-level subpath namespace. Relocate the framework-neutral RPC client surface from `@vitejs/devtools-kit/client` into `devframe/client`, including `rpc`, `rpc-shared-state`, `rpc-static`, `rpc-ws`, `static-rpc`, `docks`, and `context`. Kit now re-exports `devframe/client` plus its kit-only `remote` + `client-script` helpers, establishing that devframe must never depend on vite or any `@vitejs/*` package. Add a Dep Boundary section to AGENTS.md documenting the rule. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Hey @antfu, Code Input detected this PR has a merge conflict. The conflicts of this PR can be resolved with a semantic merge driver. Code Input can do that automatically: https://codeinput.com/r/3X89enMrIDY Let me know if you need more help with this conflict or how Code Input works. |
…ame-adapters # Conflicts: # packages/devframe/package.json # packages/devframe/tsdown.config.ts
@vitejs/devtools
devframe
@vitejs/devtools-kit
@vitejs/devtools-rolldown
@vitejs/devtools-self-inspect
commit: |
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.
Description
Namespace the six devframe adapters under
devframe/adapters/*and move the framework-neutral RPC client surface out of@vitejs/devtools-kit/clientintodevframe/client, so devframe stops depending on any@vitejs/*package and is positioned to be extracted into its own repo.devframe/{cli,build,spa,vite,kit,embedded}→devframe/adapters/{…}.rpc,rpc-shared-state,rpc-static,rpc-ws,static-rpc,docks,context(+ test) move frompackages/kit/src/client/topackages/devframe/src/client/;connectDevtoolstabilises as the public entry (alias ofgetDevToolsRpcClient). Kit's@vitejs/devtools-kit/clientbecomesexport * from 'devframe/client'+ the kit-onlyremoteandclient-scripthelpers.skills/devframe/SKILL.mdand the counter example import are updated; tsnapi snapshots regenerated undertest/__snapshots__/tsnapi/devframe/adapters/*.Linked Issues
Additional context
Verified with
pnpm lint,pnpm typecheck,pnpm test,pnpm build, and runtime import smoke-checks fordevframe/adapters/cli+devframe/client.