Skip to content

ts-ignore should error if next line is not an error #29394

Closed
@davidgomes

Description

@davidgomes

http://www.typescriptlang.org/play/#src=%2F%2F%20%40ts-ignore%0D%0Aconst%20a%3A%20number%20%3D%205%3B

In the example above, the @ts-ignore line should error because there is no TypeScript error to be ignored. This is the same behavior as Flow's suppress_comment feature.

Alternatively, if you want to maintain this behavior, consider creating a @ts-expect-error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions