mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-12 07:04:52 +09:00
Catch uncaught errors and display the error message on the page itself if bootstraping fails. This should prevent most cases of the of the web interface being stuck on "Loading web interface..." after an error was thrown and the loading failed.
6 lines
132 B
TypeScript
6 lines
132 B
TypeScript
declare function scriptError(err: any): void;
|
|
import("@clusterio/web_ui")
|
|
.then(webUi => webUi.bootstrap())
|
|
.catch(scriptError)
|
|
;
|