Breakpoints and Strict Mode
What is a breakpoint?
A breakpoint is a location in the program code in which the browser will pause the program, allowing the programmer to determine whether an error has already occurred in the script’s execution.
How can you use it?
In Google Chrome, click the line number next to the line where you want the browser to pause execution of the script.
Why would you use a breakpoint when debugging your code?
You would use breakpoints to locate the line that contains an error in your code, if any.
What is strict mode?
Strict mode is a way JavaScript can be run, in which all lapses in syntax result in load-time or run-time errors.How can you run strict mode?
In the first line of the file, simply add ”use strict”; .
Top comments (0)