-
Notifications
You must be signed in to change notification settings - Fork 36
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
"Cannot access 'aVariable' before initialization" with React #97
Comments
alexis-regnaud
changed the title
Cannot access 'aVariable' before initialization
"Cannot access 'aVariable' before initialization" with React
May 17, 2022
Any update around this? |
I have time to work on it. |
@erfanium You can add tests to https://github.com/swc-project/swc/tree/ebebd608750bf63d6f715350835a1a5349efdb68/crates/swc/tests/fixture/jest and do |
any update on fixing this issue? |
bump |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
On a React project, I switched
ts-jest
+babel-jest
to@swc/jest
Few tests are now failing with the same type of error :
Cannot access 'aVariable' before initialization
which always happen in a specific situation.The error is thrown when the variable is defined further in the component, but used before by a React function :
The text was updated successfully, but these errors were encountered: