WEBVTT

00:00.000 --> 00:04.890
So we've reached the end of section six, and we've done the work of putting in error handling into

00:04.890 --> 00:05.280
our app.

00:05.280 --> 00:10.920
And the goal of this really was to centralize our error handling as much as possible, so that as we

00:10.920 --> 00:16.080
add new features into the rest of our application, we've pretty much got centralized error handling.

00:16.080 --> 00:20.880
And we don't need to think about it too much as we're writing the logic for the features that we're

00:20.880 --> 00:22.170
going to add.

00:22.170 --> 00:26.940
And just one frequently asked question really, can we debug react in VSCode?

00:26.940 --> 00:28.950
And yes, we can.

00:28.950 --> 00:35.340
And my original intention was to include a demonstration of exactly how to do that.

00:35.340 --> 00:42.090
But the purpose of that demonstration was to show you how terrible the experience was of debugging JavaScript

00:42.090 --> 00:46.650
based code, because you end up getting taken into all the third party JavaScript, and you could be

00:46.650 --> 00:54.660
on line 15,552 as you step over a line of code and you go into third party JavaScript world.

00:54.660 --> 00:58.530
But for whatever reason, I couldn't get it to work in react 19.

00:58.530 --> 01:04.830
It worked fine in react 18, but with react 19 release candidate could not get it to work, so maybe

01:04.830 --> 01:07.500
it's something I'll revisit another time.

01:07.500 --> 01:16.230
But even then, I never use VSCode to debug JavaScript code because the humble console.log is just way

01:16.230 --> 01:22.380
more efficient when you do debug JavaScript code, then when you start the debugger, it opens your

01:22.380 --> 01:27.750
JavaScript based application in a new browser window, and then you need to do things like log in.

01:27.750 --> 01:30.330
If you need to test something that's after authentication.

01:30.330 --> 01:34.710
It's just I find the whole experience incredibly inconvenient.

01:34.710 --> 01:41.100
So I typically would always just use console.log to get information about the thing that's not behaving

01:41.100 --> 01:43.020
as I would expect it to be behaving.

01:43.020 --> 01:45.960
So I would continue to recommend just doing that.

01:45.990 --> 01:51.000
Wherever you've got a problem that something's not appearing in the user interface as it's supposed

01:51.000 --> 01:53.520
to, just use a console log and see what's going on.

01:53.520 --> 01:58.530
Also, we've got the Redux dev tools, which are really good if it's anything state related.

01:58.530 --> 02:03.120
So coming up next, then it's time to go back to adding new features to our application.

02:03.120 --> 02:07.380
And the next thing that we're going to look at is the shopping cart feature.
