Created
May 3, 2021 09:22
-
-
Save armanozak/3d758dcced1467f556acd24b6b12a22d to your computer and use it in GitHub Desktop.
[What's New in RxJS 7] RxJS 7 config.onUnhandledError #blog #rxjs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { config, throwError } from "rxjs"; | |
config.onUnhandledError = console.warn; | |
throwError(() => "TEST ERROR 1").subscribe(); | |
throwError(() => "TEST ERROR 2").subscribe({ error: console.warn }); | |
// (synchronously) TEST ERROR 2 | |
// (asynchronously) TEST ERROR 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment