Skip to content

[spaced-comment] Support typescript triple slash comments #600

@TabithaLarkin

Description

@TabithaLarkin

The default eslint rule spaced-comment does not support the triple-slash method of typescript file referencing. If it is turned on it will add a space between the second and third slash, breaking the reference.

Repro

{
  "rules": {
    "spaced-comment": ["error", "always"],
  }
}
/// <reference path="yourFile.ts" />

//A comment

Expected Result

/// <reference path="yourFile.ts" />

// A comment

Actual Result

// / <reference path="yourFile.ts" />

// A comment

Versions

package version
ESLint 5.16.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    package: eslint-pluginIssues related to @typescript-eslint/eslint-plugintriageWaiting for team members to take a look

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions