Probably a dumb question but really curious what the best way is to handle if an import like the one below fails. Could be because that remote is down or just a generic error.
If we go with the example below, I've noticed that if main is down (for example, I don't start the dev server), then the GET request that wants to get ExposedLayout just hangs and doesn't resolve at all.
const Layout = dynamic(
() => {
const mod = import('main/ExposedLayout');
return mod;
},
{ ssr: false },
);
Probably a dumb question but really curious what the best way is to handle if an import like the one below fails. Could be because that remote is down or just a generic error.
If we go with the example below, I've noticed that if
mainis down (for example, I don't start the dev server), then theGETrequest that wants to getExposedLayoutjust hangs and doesn't resolve at all.