Repository navigation
feat: add adapter-backed remote stylesheet resolution - #34
Merged
gioboa merged 3 commits intoNov 28, 2026
Merged
Conversation
commit: |
gioboa
requested changes
Nov 25, 2026
gioboa
left a comment
Collaborator
There was a problem hiding this comment.
Nice direction. Before merge:
- Rspack
external/array remotes crash with a raw TypeError - Rsbuild resolver ignores
client/serverremote overrides getRemoteStylesheets("remote/Expose")still needsresolveRemote, unlike the description- README lacks the new API
- Why change vite-host's entry to
mf-manifest.json? - Fixtures still
.catch(() => [])withoutonError
Nits: awaited onError delays rejection; .json check matches query strings; only name/alias/entry need serializing; no tests for alias, array remotes, custom resolveManifestUrl.
dmchoi77
force-pushed
the
feat/remote-css-delivery
branch
from
November 26, 2026 13:23
86738ae to
ceb8bd1
Compare
Contributor
Author
|
@gioboa Thanks for the detailed review! I addressed the issues in the follow-up changes.
The Vite host uses |
gioboa
reviewed
Nov 28, 2026
gioboa
approved these changes
Nov 28, 2026
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
This implements the minimum scope discussed in the RFC(#16): specifier-based manifest resolution, stylesheet deduplication, and stylesheet error reporting. It extends
getRemoteStylesheets("remote/Expose")to resolve manifests from Vite/Rsbuild adapter configuration, reducing manifest/expose drift, duplicate stylesheets, and silently swallowed CSS failures.Existing TanStack Start
head()/head-manager and SSR behavior remain unchanged. This does not replace the already-working pre-stream head handling or JavaScript-disabled SSR styling with a second collector.Changes
remote/Exposespecifier to the remote identity in adapter configuration. Vite injects it through a virtual module; Rsbuild uses a bundler replacement.remoteEntry.jsis sufficient for browser module loading but does not expose expose-level CSS metadata, so the resolver normalizes it to a siblingmf-manifest.jsonwhen possible and fails explicitly when no manifest can be resolved. Custom deployment layouts use the explicit API or a caller-created resolver.onError.lazyRemotewith loader-side preloading remains a follow-up improvement. The current API is usable by sharing the same specifier or providing an explicit resolver.Validation
pnpm build: passedpnpm typecheck: passed