JavaScript debug editors
Depending on the product with which you are using the JavaScript debug adapter, different editors are available for viewing or working with your JavaScript source. These editors offer different sets of debug-related functionality. For example, if you are debugging JavaScript using a Rational product such as Rational Application Developer, or a WebSphere Studio product such as WebSphere Studio Application Developer, the default editor that is associated with JSPs is Page Designer. This editor provides syntax highlighting for executable JavaScript code and the ability to set breakpoints inside of JavaScript blocks from within the editor. If you are debugging JavaScript and using the Debugger editor, you can set line breakpoints from the editor but syntax highlighting for executable JavaScript is not available.
Breakpoints can be set in JSP files within the following tags:
- JSP scriptlets of the form: <% %>
- JSP expressions of the form: <%= %>
- JSP declarations of the form: <%! %>
- jsp:useBean, jsp:getProperty, and jsp:setProperty tags
- Custom tag handlers (in the Java code)
Breakpoints cannot be set for the following tag sets:
- HTML code
- JSP directives
- All other standard JSP tags (jsp:include, jsp:forward, etc.)
- Custom tags
To choose an editor, do the following:
- Select Window > Preferences from the workbench menu bar to open the Preferences dialog box.
- In this dialog box, choose Workbench > File Associations to open the File Associations page.
- In the File types section, select the type of file that you are debugging (eg. *.jsp). If the file type does not appear in the list, click Add to add the file type.
- In the Associated editors section, click Add to open the Editor Selection dialog box.
Note: The list of available editors varies depending on the product that you are using.
- In this dialog box, ensure that the Internal Editors radio button is selected and choose the editor that you would like the file type to be associated with (for example, the Debugger Editor).
- Click OK to set the selected editor as the associated editor for the file type that you selected.
- If you would like the selected editor to be marked as the default editor, select the editor in the list and click Default.
- Click OK to close the Preferences dialog box.
After completing the above, when you open the file type to view its source, the editor (and any debug editor actions associated with it) that you specified will be available.
Related concepts
Breakpoints
Related tasks
Using breakpoints
Setting a line breakpoint