Thanks! Glad you liked it! :) This approach could be useful: - Let's assume the following application requirement. On an HTTP communication, when the response is 5xx we should to display a friendly message to the user. To accomplish this we can handle the error as early as it is possible and if it matches a potential condition we will display the error message (toast, alert, etc). While we are handling the error, we might want to return an empty list, empty object or simply to re-throw the error. - Another useful approach is when we want to retry the HTTP call. When we send an HTTP request we might get back a 5xx. There are some cases where we prompt the user to try again. Well, we can programmatically retry the same HTTP call. A combination of the catchError operator and other useful operators could do this trick
@@roman-tp6sd I think you mean the feature where we see the parameter names of a method. If so, you have to add the following line in your settings.json "typescript.inlayHints.parameterNames.enabled": "all"
Hello Mr Profanis thank you for this nice video. I have one question please. Can you give us 1 or 2 examples where this approach could be useful?
Thanks! Glad you liked it! :)
This approach could be useful:
- Let's assume the following application requirement. On an HTTP communication, when the response is 5xx we should to display a friendly message to the user. To accomplish this we can handle the error as early as it is possible and if it matches a potential condition we will display the error message (toast, alert, etc). While we are handling the error, we might want to return an empty list, empty object or simply to re-throw the error.
- Another useful approach is when we want to retry the HTTP call. When we send an HTTP request we might get back a 5xx. There are some cases where we prompt the user to try again. Well, we can programmatically retry the same HTTP call. A combination of the catchError operator and other useful operators could do this trick
@@CodeShotsWithProfanis thank you for yor answer! It is crystal clear now
The best explanation for me. Thank you so much.
Glad to hear that!
Very helpful. Tho was just implementing ThrowError and it is now changed so it has to be like this: ThrowError(()=> err). But otherwise the same
Thanks for this. Indeed, the API changed
Never disappointing Fanis!!! Thanks a bunch!!!!
Many thanks Tito!!
It's a really good video Mr Profanis, awesome job! 🤟
Thanks for your feedback, and glad you liked it! :)
You explained this very clearly--thank you! This is exactly what I needed.
Glad it was helpful!
Very good explanation
Have a nice day!!
Many thanks for your feedback!
Have a great day ahead of you :)
such clear explanation) thx
Glad you liked it!
Thanks sir !
Great as usual!
Thanks a lot!
Glad you liked it :)
What vs code extension use?
I have many of them :)
Which feature did you like the most, so that I can share with you the extension name?
@@CodeShotsWithProfanisfor example in subscribe object auto complete properties next, error
@@roman-tp6sd I think you mean the feature where we see the parameter names of a method.
If so, you have to add the following line in your settings.json
"typescript.inlayHints.parameterNames.enabled": "all"
@@CodeShotsWithProfanis yessssssss tnx!!!!
how to assign data to aray element
can you be more specific?
I thought your voice was generated by a software
. lol.
hahaha
I.AM.NOT.A.ROBOT