Add Blazor.onServerConnectionClose to fix #1339

This API will be removed once we implement proper connection management (reconnects, etc.)
This commit is contained in:
Steve Sanderson 2018-08-21 15:34:20 +01:00
parent 1089eecbfc
commit 13cf5bd583
1 changed files with 4 additions and 0 deletions

View File

@ -47,6 +47,10 @@ function boot() {
);
})
.catch(unhandledError);
// Temporary undocumented API to help with https://github.com/aspnet/Blazor/issues/1339
// This will be replaced once we implement proper connection management (reconnects, etc.)
window['Blazor'].onServerConnectionClose = connection.onclose.bind(connection);
}
function unhandledError(err) {