From the course: Learning JavaScript Debugging

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Explore other breakpoint options

Explore other breakpoint options - JavaScript Tutorial

From the course: Learning JavaScript Debugging

Start my 1-month free trial

Explore other breakpoint options

- [Instructor] breakpoints that pause execution are really useful by themselves, but we do have some other options for how we can stop and look around under different conditions. Let's take a look at some of those. Here's a fresh example that looks just like the ones we've seen before, but it's a little different, and has a small bug. Let's take a look at what that bug is. I'm going to open this colorbox, and now take a look at what's happening when I swipe in either direction with this image counter. So if I swipe left, I'm moving forward through the images, which is what I would expect, but then if I swipe right, I'm still moving forward through the images. So, we're not quite doing the right thing here, and we're gonna fix it. So I'm gonna open up my developer tools with command + option + I. And here in the sources pane, I'm going to open the index.html file where my JavaScript is, and scroll all the way down. So here's our new implementation. Instead of using swipe left and swipe…

Contents