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

Make adding semicolon configurable for "Extract function" #18780

Closed
mjbvz opened this issue Sep 26, 2017 · 2 comments · Fixed by #32903
Closed

Make adding semicolon configurable for "Extract function" #18780

mjbvz opened this issue Sep 26, 2017 · 2 comments · Fixed by #32903
Labels
Awaiting More Feedback This means we'd like to hear from more people who would be helped by this feature Domain: Refactorings e.g. extract to constant or function, rename symbol Suggestion An idea for TypeScript

Comments

@mjbvz
Copy link
Contributor

mjbvz commented Sep 26, 2017

From @davedmarketing on September 24, 2017 17:53

  • VSCode Version: (1.16.1)
  • OS Version: OSX 10.11.6

Steps to Reproduce:

When I use "Extract function" it automatically adds ";". I don't use ";" when writing javascript except for inline "line breaks" or in front of self-executing functions so this causes a discrepancy.

Reproduces without extensions: Yes/No

Copied from original issue: microsoft/vscode#34911

@mjbvz mjbvz self-assigned this Sep 26, 2017
@mhegazy mhegazy changed the title How to remove automatically added ";" from "Extract function" Make adding semicolon configurable for "Extract function" Sep 26, 2017
@mhegazy mhegazy added Domain: Refactorings e.g. extract to constant or function, rename symbol Suggestion An idea for TypeScript labels Sep 26, 2017
@mhegazy mhegazy removed the Domain: Refactorings e.g. extract to constant or function, rename symbol label Sep 26, 2017
@mjbvz
Copy link
Contributor Author

mjbvz commented Nov 16, 2017

May fall within scope of #19882

@mjbvz
Copy link
Contributor Author

mjbvz commented Aug 12, 2019

Just a heads up @andrewbranch, I did a quick test on this issue it looks like this was not fixed by your work on #19882

Here's a quick repo that triggers the detector not to use semicolon for auto imports:

console.log(1)
console.log(2)
console.log(3)
console.log(4)
console.log(5)
console.log(6)

console.log(1 + 2) // extract `1 + 2` here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting More Feedback This means we'd like to hear from more people who would be helped by this feature Domain: Refactorings e.g. extract to constant or function, rename symbol Suggestion An idea for TypeScript
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants