react-reconciler renderers (react-three-fiber) crash at import: the react shim has no __CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE (0.2.1, 0.3.1)
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 55/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- react, typescript
- Domínio
- developer-experience, frontend
Direção de pesquisa
Start by reading the Vite plugin’s React shim at dist/react/index.js and tracing how the plugin substitutes it during dependency pre-bundling. Check how react-reconciler accesses __CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, then compare the proposed shim change with the alternative importer-level skip behavior. Done when a reproducer using @react-three/fiber imports and mounts successfully, or the supported limitations and workaround are documented.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
What happens
Any react-reconciler based renderer breaks under the Vite plugin. With @react-three/fiber in the app, the first import of its module throws and the page never renders:
TypeError: Cannot read properties of undefined (reading 'S')
at createReconciler (react-three-fiber.esm-*.js)
The pre-bundled fiber chunk resolves react to @tanstack/redact/dist/react/index.js. react-reconciler reads React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE at module evaluation and then .S on it; the shim does not export that object, so the read is on undefined. Same in 0.2.1 and 0.3.1 (dist/react/index.js has no __CLIENT_INTERNALS in either).
Reproduction
- Vite 8.3.4,
@vitejs/plugin-react6.1.2,react/react-dom19.3.1,@react-three/fiber9.8.2,three0.186.1,@tanstack/redact0.2.1 (also 0.3.1). vite.config.ts:plugins: [viteReact(), redact()].- Render any component that imports
Canvasfrom@react-three/fiber.
Expected: the canvas mounts. Actual: the error above at import time; Storybook and Vitest, which do not run the plugin, render the same component fine.
What I tried
skip is global per specifier, so there is no way to leave one package (or one subtree) on real React while the rest of the app uses Redact. Removing the plugin fixes it.
Ask
Either expose the client internals that react-reconciler needs so custom renderers can host their own root inside a Redact tree, or document that react-reconciler renderers (@react-three/fiber, @react-pdf/renderer, ink) are out of scope and let skip exclude an importer, not only a specifier.
- Linguagem predominante
- TypeScript
- Estrelas
- 537
- Forks
- 22
- Merge médio
- 10h 27min
- PRs com merge (30d)
- 40
Preparar o ambiente
Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de TanStack/redact
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
TanStack/redact#142 · 3 comentários ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 85/100
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 35/100
Mantenedores costumam responder em até 1 dia
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 54/100
Mantenedores costumam responder em até 1 dia
Todas as issues de TanStack/redact
Issues semelhantes
-
Chip source filter and denial markers miss Storage rows when a Storage activity source is pickedAbertabug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 77/100
omdsh-dev/DSH-better-sidebar#1141 ·
Mantenedores costumam responder em até 2 dias
-
desktop linux photos
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
Cleanup SetupTalvez já em andamento @AlexanderKaran assumiu hoje. Abertadocumentation enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 64/100
e18e/framework-tracker#769 ·
Mantenedores costumam responder em até 1 dia
-
fix(docker): correct stale --db-path comments in fetch/git Dockerfiles and clarify git READMEAbertabug v2
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 88/100
modelcontextprotocol/servers#5483 ·
Mantenedores costumam responder em até 1 dia