Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
Your browser does not support iframes.
titleLive example

If you want to see a live example of the capabilities of the JavaScript plugin, you can have a look at the analysis of the jQuery project on Nemo.

Description / Features

The JavaScript plugin enables analysis of and reporting on JavaScript projects with SonarQube..

  • 75 predefined rules
  • custom coding rules with XPath
  • import of code coverage results with LCOV

titleSince version 2.0

Analysis support of ECMAScript 6 new constructs, see ES6 features (by Luke Hoban)

Include Page
Include - Plugin Installation
Include - Plugin Installation


Run an Analysis with the SonarQube Runner (Recommended



To run an analysis of your JavaScript project, use the SonarQube Runner.


  1. Prior to the SonarQube analysis, execute your unit tests and generate the LCOV report.
  2. Import this report while running the SonarQube analysis by setting the sonar.javascript.lcov.reportPath property to the path to the LCOV report. The path may be absolute or relative to the project base directory.

(info)  Since the plugin version 2.0, you can force coverage value to be set to "0" without providing any report. You just need to set the following property to "true": sonar.javascript.forceZeroCoverage.

A sample project can be browsed or downloaded: /projects/languages/javascript/javascript-sonar-runner-lcov

Unit Tests 
titlecoming (again) soon

The ability the import unit tests results into SonarQube was removed from the JavaScript plugin in version 1.5, but will be re-introduced in version 2.2 (the next release).

See the related Jira ticket for more detail: SONARJS-239


See Metrics documentation page.


To navigate the AST, download the SSLR JavaScript Toolkit.

Release Notes

Version 1.5

It is no longer possible to:

  • let SonarQube drive the execution of unit tests
  • import unit test execution reports