BuilderIO / hydration-overlay

Overlay for hydration errors with explicit diff between renders.

Home Page:https://www.builder.io/blog/announcing-react-hydration-overlay

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Gives a module error

malikozturkk opened this issue · comments

It didn't work with both Webpack and plain config.
next.config.js
webpack: (config, options) => {
config = withHydrationOverlayWebpack({
appRootSelector: "#__next",
isMainAppEntryPoint: (entryPointName) =>
!options.isServer &&
(entryPointName === "pages/_app" || entryPointName === "main-app"),
})(config);
return config;
},

_app.tsx


<Page {...pageProps} />

Screenshot 2023-12-21 at 11 16 28

Fixed by adding @builder.io/react-hydration-overlay to next.config transpilePackages

transpilePackages: ['@builder.io/react-hydration-overlay'],

@saadshahd nice! it got rid of the server error.

But I don't have the HTML diff showing up still.
Am I the only one?

Fixed by adding @builder.io/react-hydration-overlay to next.config transpilePackages

transpilePackages: ['@builder.io/react-hydration-overlay'],

Thanks, I'm trying

Fixed by adding @builder.io/react-hydration-overlay to next.config transpilePackages

transpilePackages: ['@builder.io/react-hydration-overlay'],

Thanks!!

it worked