Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// Keep in sync with react-dev-utils/errorOverlayMiddleware
// eslint-disable-next-line no-undef
fetch(`${launchEditorEndpoint}?fileName=${fileName}&lineNumber=${lineNumber}`);
});
hotClient.useCustomOverlay({
showProblems(type, errors) {
reportBuildError(formatWebpackMessages({ errors, warnings: [] }).errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({ name: 'client', reload: true });
startReportingRuntimeErrors({ filename: '/assets/client.js' });
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}
hotClient.useCustomOverlay({
showProblems(type, errors) {
const formatted = formatWebpackMessages({
errors,
warnings: [],
});
reportBuildError(formatted.errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({
name: 'client',
reload: true,
});
startReportingRuntimeErrors({
filename: '/assets/client.js',
});
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}
hotClient.useCustomOverlay({
showProblems(type, errors) {
const formatted = formatWebpackMessages({
errors,
warnings: [],
});
reportBuildError(formatted.errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({
name: 'client',
reload: true,
});
startReportingRuntimeErrors({
launchEditorEndpoint,
filename: '/assets/client.js',
});
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}
hotClient.useCustomOverlay({
showProblems(type, errors) {
const formatted = formatWebpackMessages({
errors,
warnings: [],
});
reportBuildError(formatted.errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({
name: 'client',
reload: true,
});
startReportingRuntimeErrors({
filename: '/assets/client.js',
});
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}
hotClient.useCustomOverlay({
showProblems(type, errors) {
const formatted = formatWebpackMessages({
errors,
warnings: [],
});
reportBuildError(formatted.errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({
name: 'client',
reload: true,
});
startReportingRuntimeErrors({
filename: '/assets/client.js',
});
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}
hotClient.useCustomOverlay({
showProblems(type, errors) {
const formatted = formatWebpackMessages({
errors,
warnings: [],
});
reportBuildError(formatted.errors[0]);
},
clear() {
dismissBuildError();
},
});
hotClient.setOptionsAndConnect({
name: 'client',
reload: true,
});
startReportingRuntimeErrors({
filename: '/assets/client.js',
});
if (module.hot) {
module.hot.dispose(stopReportingRuntimeErrors);
}