Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(scope-manager): fix incorrect handling of class decorators and class method default params #2943

Merged
merged 1 commit into from Jan 19, 2021

Conversation

bradzacher
Copy link
Member

Fixes #2941
Fixes #2942

This was a regression introduced by #2751

…ass method default params

Fixes #2941
Fixes #2942

This was a regression introduced by #2751
@bradzacher bradzacher added the bug Something isn't working label Jan 19, 2021
@typescript-eslint
Copy link
Contributor

Thanks for the PR, @bradzacher!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint. As a thank you, your profile/company logo will be added to our main README which receives thousands of unique visitors per day.

@codecov
Copy link

codecov bot commented Jan 19, 2021

Codecov Report

Merging #2943 (cabfcf7) into master (60c5dcd) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #2943   +/-   ##
=======================================
  Coverage   92.73%   92.74%           
=======================================
  Files         313      313           
  Lines       10632    10636    +4     
  Branches     3016     3017    +1     
=======================================
+ Hits         9860     9864    +4     
  Misses        353      353           
  Partials      419      419           
Flag Coverage Δ
unittest 92.74% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...kages/scope-manager/src/referencer/ClassVisitor.ts 91.66% <100.00%> (+0.32%) ⬆️

@astlaurent1
Copy link

astlaurent1 commented Jan 20, 2021

@bradzacher We ran into this issue when installing latest today, which gave us v4.14.0. By any chance would you be able to create the v4.14.1 with this fix?

@bradzacher
Copy link
Member Author

https://github.com/typescript-eslint/typescript-eslint#package-versions

This will be released on Monday. If you need it sooner, it's available on the canary tag

@Machine-Maker
Copy link

Is this the fix for
image
(getting no-undefs in decorators.

I tried installing the canary tag, and im still getting the no-undefs. (yarn add -D @typescript-eslint/scope-manager@canary)

@bradzacher
Copy link
Member Author

I tried installing the canary tag, and im still getting the no-undefs. (yarn add -D @typescript-eslint/scope-manager@canary)

You need to install the new version of the packages you're actually using - not a transient dependency.

Our packages all intentionally have their dependencies pinned to a specific version to ensure the state is consistent.
By installing just scope-manager, all you've done is installed that package locally - the old version is still installed and used at lint time because of the pinning..

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

A lot of no-undef in Vue @Component decorators after parser update @typescript-eslint/no-use-before-define
3 participants