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
var to let/const
with empty destructuring
#350
Comments
What is the reason of the empty destructing? Type assertion? |
I think the main reason why it exist is just because we can, it valid syntax 😮💨 And you cannot simply remove the statement as the statement will trigger a [get]. |
I didn't mean to be aggressive. I'm wondering why someone/something writes those statements. |
Oh I get a sense that it's a testing for the syntax itself not for specific logic/side-effect, is that correct? |
yes |
The rule
var to let/const
will not transform empty destructuring.This is not the code that an average human would write. I noticed this pattern from
babel
's test case and my codemod test.Input
Actual Output
Expected Output
The text was updated successfully, but these errors were encountered: