We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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
TypeScript Version: 3.3.1
Search Terms: jsx extract constant refactoring quick fix
Code
<Foo><Bar /></Foo>;
when selecting <Bar /> and actioning "extract to constant in enclosing scope"
<Bar />
Expected behavior:
const newLocal = <Bar />; <Foo>{newLocal}</Foo>;
Actual behavior:
(missing braces)
const newLocal = <Bar />; <Foo>newLocal</Foo>;
The text was updated successfully, but these errors were encountered:
When using "Extract to function in module scope" the braces are missing as well.
Sorry, something went wrong.
Thanks @a-tarasyuk!
This still happens when using fragments: #44249
@OliverJAsh Ok, will check
@a-tarasyuk I think I figured it out: #44252
Successfully merging a pull request may close this issue.
Uh oh!
There was an error while loading. Please reload this page.
TypeScript Version: 3.3.1
Search Terms: jsx extract constant refactoring quick fix
Code
when selecting
<Bar />
and actioning "extract to constant in enclosing scope"Expected behavior:
Actual behavior:
(missing braces)
The text was updated successfully, but these errors were encountered: