undici
undici copied to clipboard
Error handling?
This would solve...
It doesn’t look like there’s anything in the documentation on error handling, except perhaps only statusCode.
For comprehensiveness, I would suggest it be considered important to include error handling in the first example.
PR is welcome
Sure. Can you point me to the code that does error handling?
@ronag Would a PR implementing (opt-in) error throwing for 4xx and 5xx responses be accepted?
I do not see a problem with having it as an option.