BREAKPOINTS AND STRICT MODE
Breakpoints are locations where the browser will pause the program, this enables the programmer to know if the error has occurred at that point of the script’s execution.
One can use breakpoints in the Google Chrome browser on a Mac by first right clicking on the page and then going to “Inspect”. On the line of code, to the left, there are three dots. Once clicked, after the options appear, proceed to “Break on” and select from the available options.
The purpose of using breakpoints when debugging your code is so that you can systematically figure out where the error in your code is. Since the code will only be run until the breakpoint, one can then progressively debug code.
The way to run strict mode is by inputting the “use strict”; statement on the first line of the file.