function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
SahebSamantaSahebSamanta 

Debug Lightning Component Execution

Hi,
Can anyone suggest what is the best way available to debug lightning component's javascript execution?
Mark SFMark SF
Here are a few ideas.

1. Turn on debug mode.
   a. From Setup, click Develop > Lightning Components.
   b. Select the Enable Debug Mode checkbox.
   c. Click Save.

2. In Chrome Developer Tools, check the "Pause on Caught Exceptions" checkbox in the Sources tab. This can often help finding the source of an issue. Other browsers may have similar options. 

3. Add a debugger statement if you want to step through some code. 
debugger;
This is useful when you have a rough idea where the problem might be happening.