SonarTS icon indicating copy to clipboard operation
SonarTS copied to clipboard

FP no-commented-code: "tslint:disable" comments

Open xxluke opened this issue 5 years ago • 3 comments

I want to report a bug.

grafik

TSLint version: 5.12.1 TSLint-SonarTS version: 1.9.0

Reproducer

// tslint:disable:no-identical-functions
// tslint:disable:no-duplicate-string

The no-commented-code TSLint rule thinks this is commented code.

This seems to be an issue of the TSLint rule only and not the normal Sonar rule.

xxluke avatar Jan 22 '19 05:01 xxluke

@xxluke thanks for reporting that! Good catch

vilchik-elena avatar Feb 01 '19 12:02 vilchik-elena

Same problem here. Any news?

gabsprates avatar Feb 25 '19 18:02 gabsprates

Workarounds are to add an empty line between the comments

// tslint:disable:no-identical-functions

// tslint:disable:no-duplicate-string

or to disable both rules in one line

// tslint:disable:no-identical-functions no-duplicate-string

xxluke avatar Aug 19 '19 14:08 xxluke