AI & Agent Dev Bug Sandbox logo
AI & Agent Dev Bug Sandbox
Back to Radar

Scoped Styled-Jsx Loses Jsx-<Hash> Class On Conditionally Rendered Elements Under TurbopackRustReactCompiler

When experimental.turbopackRustReactCompiler is enabled with reactCompiler:true, conditionally rendered styled-jsx elements in stateful components do not receive the jsx-<hash> scoping class, causing CSS selectors to silently fail.

highConfidence 85%Next.jsReact Server ComponentsHydrationAffected V16.3.0

Origin Analysis

The Rust React Compiler port fails to propagate styled-jsx scoping attributes to conditional JSX branches during transformation, unlike the Babel plugin path.
1. Create Next.js 16.3.0 app with reactCompiler:true. 2. In a stateful client component, conditionally render a styled-jsx element inside a <style jsx> block. 3. Run with RUST_COMPILER=1 next dev and inspect SSR output; the jsx-<hash> class is missing.

Fixing Code Block

Edge Case Audit

This hotfix disables the Rust compiler port, potentially reducing build performance or bleeding-edge optimizations. Roll back by setting turbopackRustReactCompiler back to true once upstream fix lands. Test all styled-jsx usages after re-enabling. No changes needed to component code.

Ecosystem Topology

Agent Frameworks

LangChain, LlamaIndex, and Pydantic

  1. highProperty graph relation keys collide when entity IDs or labels contain underscores
  2. highCodeActAgent drops assistant tool-call metadata during handoff, leaving an orphan tool response
  3. high[Bug]: HierarchicalNodeParser async methods return the documents unsplit
  4. highLLM.predict_and_call fails with ValidationError for non-function-calling models when react_chat_formatter is omitted
  5. highAnthropic streaming server-tool input_json_delta overwrites completed client tool_use arguments due to stale cur_tool_call state