I've been migrating the current website of my company from React to Astro, but still keeping a few React components.
When running the "astro build" command (yarn), I got the following error message
"Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object."
File
./node_modules/react-dom/cjs/react-dom-server.node.production.min.js
I can't figure out what component is causing the issue, neither any wrong coding related to it.
With yarn run dev, everything runs normally