Skip to content

支持带基座启动 vite + React 子应用吗? #661

Closed
@festina-lente-z

Description

@festina-lente-z

Clear and concise description of the problem

是否支持 vite + React 子应用?目前没有看到 demo。vite子应用只看到 vue 版本的。

复现了一个 demo:https://github.com/festina-lente-z/react-vite-garfish-demo

image
发现子应用引入的代码并没有执行。


更新:我把 @vitejs/plugin-react-swc 插件注释掉,子应用就可以渲染出来了😂
[2024-03-26 更新]:在最小 demo 子应用可以渲染,但是转移到公司项目上还是不行,我参考了这个 #611 直接修改了 node_modules 里面的代码,发现是因为项目代码存在一些间接循环引用问题,修改后便可以渲染出来 🎉~~~~

Suggested solution

支持vite+React子应用

Alternative

No response

Additional context

No response

Validations

  • Read the Contributing Guidelines.
  • Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions