A great post, love it! ❤️
One thing though, when you described API of a subject for throwing errors there’s a tiny typo: it’s .error() function, not .throw() 😉
Thanks Stas! Nice catch, I have missed it since the console showed the expected output... the word error :)
error
Adding the error message to the console showed
-- error with message: observer.throw is not a function
and now it shows the expected error
-- error with message: something bad happened
I updated the post accordingly, Thanks again!
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
A great post, love it! ❤️
One thing though, when you described API of a subject for throwing errors there’s a tiny typo: it’s .error() function, not .throw() 😉
Thanks Stas!
Nice catch, I have missed it since the console showed the expected output... the word
error
:)Adding the error message to the console showed
and now it shows the expected error
I updated the post accordingly, Thanks again!