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

Move to new file causes inconsistent quote style #50680

Closed
octref opened this issue May 29, 2018 · 2 comments
Closed

Move to new file causes inconsistent quote style #50680

octref opened this issue May 29, 2018 · 2 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug

Comments

@octref
Copy link
Contributor

octref commented May 29, 2018

#50486

My setting:

"typescript.preferences.quoteStyle": "auto"

Have file a.ts:

import { bar } from './b';

function foo() {
  bar()
}

foo()

b.ts:

export function bar() {

}

Run Move to new file on the foo function.

a.ts becomes:

import { foo } from "./foo";



foo()

foo.ts becomes:

import { bar } from './b';
export function foo() {
  bar();
}

The import statements have different quoting style.

@mjbvz
Copy link
Collaborator

mjbvz commented May 29, 2018

Bug is that auto's detected style gets lost during the removal of the old imports in a.ts

You can fix this by explicitly setting the quote preference to single: microsoft/TypeScript#24363

@mjbvz mjbvz added the bug Issue identified by VS Code Team member as probable bug label May 29, 2018
@mjbvz
Copy link
Collaborator

mjbvz commented Jun 1, 2018

This issue was moved to microsoft/TypeScript#24605

@mjbvz mjbvz closed this as completed Jun 1, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Jul 16, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug
Projects
None yet
Development

No branches or pull requests

2 participants