Getting TypeError: Cannot read properties of null (reading 'useState') #221
Replies: 5 comments 6 replies
-
Hello. Any suggestions that could help solve this problem? |
Beta Was this translation helpful? Give feedback.
-
Any help on this ? |
Beta Was this translation helpful? Give feedback.
-
Any work around to fix this ?? |
Beta Was this translation helpful? Give feedback.
-
Any updates on this? I'm facing the same problem, components, if remote components exported are not using React... which is un-useful. |
Beta Was this translation helpful? Give feedback.
-
I have the solution for this: #242 (comment) We should have a working solution compatible with the last version of the library though. |
Beta Was this translation helpful? Give feedback.
-
I am trying to setup two React + Vite + Typescript applications, one host, the other remote using the vite-plugin-federation. After building and running both applications using
vite preview
, when running the host app I am getting the following error:My Vite config for each of the apps are as follows:
Host app
Remote app
I have tried various combinations of the config but nothing works by referring to React ESM example (which uses rollup), also looked at vue3-demo-webpack-esm-esm example for reference. Next step, once this works, is for me to try to make React + Webpack + Typescript app as host and React + Vite + Typescript app as remote.
Plz help me understand what I might be missing.
Find repro here. I have committed the
dist
folders of the apps here for reference of the files generated after the build.Beta Was this translation helpful? Give feedback.
All reactions