Closed alvarogonoring closed 7 months ago
Apparently the piece of code using the NextJS dynamic import is not wrong at all, but it needs to be executed outside the scope of the React component, this way:
let PowerbiEmbedded;
PowerbiEmbedded = dynamic(() => import('nextjs-powerbi').then(component => component.default), {
ssr: false,
})
export default function MyReactComponent() {
return (
<PowerbiEmbedded />
)
}
As some of you already known, this issue isn't a new one, but also i've run out of options... already tried the NextJs dynamic import, safe hydration and the use of the useEffect hook as suggested in other past issues.
After running script next build, the follow error is returned (compiling locally is all good):
Even all of this togheter as you can see in the code below: