

#WEBSTORM FILEWATCHER BABEL ERROR CODE#
You can clean up your code in files before they are committed to Git. Otherwise, the cleanup will run in the file that is currently opened in the editor.įrom the main menu, select Code | Analyze Code | Silent Code Cleanup.Ĭlean up your code before committing it to Git Select the node in which you want to clean up your code in the Project tool window Alt+1. In this case, the IDE runs the cleanup inspections from the profile that is currently configured in the settings. You can also run the code cleanup in the silent mode without displaying the Specify Code Cleanup Scope dialog. WebStorm performs code analysis and applies quick-fixes from the selected inspection profile to the detected issues.Īlternatively, you can place the caret at an error in the source code that corresponds to a quick-fix, click the red bulb (suggested quick-fix) that appears on the left, and select Code Cleanup from the menu. You can also click Configure to view all code cleanup inspections and their settings. Select the inspection profile from the Inspection profile list, or click Configure to create a new profile. In the Specify Code Cleanup Scope dialog, select the scope to which you want to apply a profile. Batch-apply quick-fixes (Code Cleanup)įrom the main menu, select Code | Code Cleanup. To view the list of these inspections, open the Settings dialog by pressing Ctrl+Alt+S and go to Editor | Inspections, click, and enable the Show only cleanup inspections option. This allows you to batch-apply quick-fixes to the selected scope without examining each problem individually.ĭuring the cleanup, the IDE applies fixes from the code cleanup inspections in the selected inspection profile. You can streamline the process of fixing problems in your code by running Code Cleanup. Select the problem description, click icon on the toolbar, select the relevant fix, and then select Fix all "" in file from the list. If a problem occurs several times in a file, you can fix all the occurrences at once. You can also press Alt+Enter and select a suitable fix from the popup menu. To fix a problem, click the icon on the toolbar or in the context menu. Click a problem to display inspection details on the right. All detected problems are listed in the left part of the tool window. If you have invoked inspections manually, you can examine the results in the Problems tool window that opens automatically after the analysis is finished. Select the relevant fix and then select Fix all "" in file from the list. Place the caret at the highlighted piece of code and press Alt+Enter. If a detected problem occurs several times in a file, WebStorm suggests fixing them all at once. Fix all occurrences of a problem in the current file Place the caret at the highlighted piece of code and press Alt+Enter.įor some inspections, for example, Assignment used as condition, Unreachable 'case' branch of a 'switch' statement, Assignment used as condition, and others, you can open a preview by pressing Ctrl+Q ( View | Quick Documentation). If an inspection has detected a problem in your code, you can quickly apply a fix in the editor.
