Skip to content

Commit b6e57e4

Browse files
committed
cleanup
1 parent 767ce1e commit b6e57e4

1 file changed

Lines changed: 0 additions & 25 deletions

File tree

packages/plugin-rsc/src/plugin.ts

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -749,31 +749,6 @@ export default function vitePluginRsc(
749749
// leaves the stale rule live on <style> and the cascade still
750750
// wins over the refreshed <link>
751751
return ctx.modules.filter((mod) => mod.type !== 'css')
752-
} else if (this.environment.name === 'rsc') {
753-
// Walk importers of the changed CSS and invalidate every derived
754-
// `\0virtual:vite-rsc/css?type=rsc&...` module — those emit
755-
// <link rel="stylesheet"> into the Flight stream via collectCss +
756-
// normalizeViteImportAnalysisUrl
757-
// Without invalidation the next render reuses the cached transform
758-
// with the pre-edit href
759-
// JS importers (inner.tsx, server.tsx, ...) are left alone — only
760-
// the derived CSS virtual needs recomputing
761-
// const visited = new Set<string>()
762-
// const walk = (mod: EnvironmentModuleNode) => {
763-
// if (!mod.id || visited.has(mod.id)) return
764-
// visited.add(mod.id)
765-
// if (mod.id.startsWith('\0virtual:vite-rsc/css?')) {
766-
// this.environment.moduleGraph.invalidateModule(mod)
767-
// }
768-
// for (const imp of mod.importers) {
769-
// walk(imp)
770-
// }
771-
// }
772-
// for (const mod of ctx.modules) {
773-
// for (const imp of mod.importers) {
774-
// walk(imp)
775-
// }
776-
// }
777752
}
778753
}
779754

0 commit comments

Comments
 (0)