Operation Manual

Table Of Contents
400
Coding
Last updated 11/30/2015
2 Enable linting and specify when the linting should be triggered. You can lint files when they are loaded, saved, or
edited. See
Enable linting and set preferences for more information.
Errors and warnings found in the files are displayed in the output panel. For more information, see Linting results and
the Output panel .
Enable linting and set preferences
Click Edit > Preferences (Win) or Dreamweaver > Preferences (Mac). Select Linting in the Category list.
Select Enable Linting.
Specify one or more triggers for linting. You can trigger linting when the file gets loaded, saved, and/or edited.
Specify linting rules
You can lint HTML, CSS, and JS files by editing the linting rules in the corresponding configuration files:
HTML: DW.htmlhintrc
CSS: DW.csslintrc
JS: DW.jshintrc
To access and edit these files, perform the following steps:
1 Click Edit > Preferences (Win) or Dreamweaver > Preferences (Mac).
2 Select Linting in the Category list.
3 In the Edit Rule Set section, click the required file type and click Edit & Apply Changes.
The corresponding configuration file opens in Dreamweaver.
4 Edit or add linting rules to the configuration files. Refer to the following documentation for more information on
linting rules:
HTML Linter: https://github.com/yaniswang/HTMLHint/wiki/Rules
CSS Linter: https://github.com/CSSLint/csslint/wiki/Rules
JS Linter: http://jshint.com/docs/options/
In these configuration files, you can also set the type of errors or warnings to be displayed. In JS configuration files,
you can also set the maximum number of errors to be found.
Linting results and the Output panel
The linting results - errors and warnings - are listed in the Output panel. The Output panel is available in the docked
mode at the bottom of all default workspaces. If the Output panel is closed, you can open it by performing one of the
following actions:
By clicking the linting status icon in the Document window status bar
Using the keyboard shortcut, Shift+F6
Using Window > Results > Output