denoland / deno_lint

Blazing fast linter for JavaScript and TypeScript written in Rust
https://lint.deno.land/
MIT License
1.51k stars 163 forks source link

`no-var`: report on the `var` keyword, not the entire var declaration #1200

Closed lucacasonato closed 7 months ago

lucacasonato commented 8 months ago

Lint Name

no-var

Code Snippet

var foo = "1";

Expected Result

The lint is reported here:

var foo = "1";
^^^

Actual Result

The lint is reported here:

var foo = "1";
^^^^^^^^^^^^^^

Version

deno 1.37.1 (release, aarch64-apple-darwin)
v8 11.8.172.3
typescript 5.2.2