eslint / eslint-scope

eslint-scope: ECMAScript scope analyzer
BSD 2-Clause "Simplified" License
125 stars 30 forks source link

feat!: support class static blocks #80

Closed mdjermanovic closed 3 years ago

mdjermanovic commented 3 years ago

This PR adds new "class-static-block" scopes. Each StaticBlock node creates a "class-static-block" scope.

https://github.com/tc39/proposal-class-static-block

Notes:

I tagged this as a breaking change as I'd like to suggest that we bump major version. While this is a new syntax for eslint-scope, parsers (including Espree) already support this syntax, and inserting a new scope where it didn't exist before looks like a relatively big change in scope analysis (from wrong to right, but still).