-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
Bug Report
Description
The Row component from @lightningtv/solid/primitives throws "React is not defined" error when used in Storybook within a Rush monorepo, but works fine in standalone projects.
Environment
@lightningtv/solid: 3.0.10@lightningjs/renderer: 3.0.0-beta21- Storybook: 9.1.17 with
storybook-solidjs-vite - Rush monorepo with pnpm
Error
ReferenceError: React is not defined
at Row (Row.tsx:32:3)
Reproduction
- Works: Clone
lightning-tv/solid-starter-template, add Row to Storybook → works perfectly - Fails: Same Row component in Rush monorepo with pnpm → React error
Root Cause Analysis
Rush + pnpm hoists Storybook's React dependencies to shared common/temp/node_modules/.pnpm/. The Row component appears to detect React's presence and tries to use it, but fails because React 19 has no default export.
Configuration Attempted
- React shim aliases
- optimizeDeps exclusions
- Multiple Vite configurations
- Package version matching (App is using older versions and I tried upgrading to the latest)
The issue appears to be that @lightningtv/solid has conditional React usage that conflicts with hoisted React in monorepos.
Expected Behavior
Row component should work in monorepo environments without React conflicts.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels