BlazorWorker
BlazorWorker copied to clipboard
Add native support for CancellationToken
Also an extension method CancellationToken.ThrowIfCancellationRequestedAsync() which would call CancellationToken.ThrowIfCancellationRequested after having called Task.Delay(1), to allow for Context switch to read incoming requests for cancellation
Mentioned in https://github.com/dotnet/aspnetcore/issues/17730#issuecomment-879407934_ but as a full process kill, which is not really neccessary unless you would want to unload any dynamically generated dlls