Handling the Error Event in Node6:20 with Andrew Chalkley
Often a lot of the APIs give you an "error" event to listen to. In this video we'll handle this type of error event.
www to the URL in the GET request on line 15 no longer results in an unhandled error event. Now it causes a
SyntaxError: Unexpected end of JSON input to be thrown instead. To generate the unhandled error event and practice the solution demonstrated in the video, you can substitute
You need to sign up for Treehouse in order to download course files.Sign up