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

Cannot move symbols from tsx to ts files #57302

Closed
jrieken opened this issue Feb 5, 2024 · 4 comments · Fixed by #57305
Closed

Cannot move symbols from tsx to ts files #57302

jrieken opened this issue Feb 5, 2024 · 4 comments · Fixed by #57305
Labels
Bug A bug in TypeScript Help Wanted You can do this

Comments

@jrieken
Copy link
Member

jrieken commented Feb 5, 2024

  • have tsx file with some function
  • select the function, invoke the "move to file" code action
  • the picker doesn't allow for ts files, only tsx files
@mjbvz
Copy link
Contributor

mjbvz commented Feb 5, 2024

Are they part of the same tsconfig project? We only show files within a project

@mjbvz
Copy link
Contributor

mjbvz commented Feb 5, 2024

Actually pretty easy to repo:

foo.ts

export function foo() {
    console.log('foo');
}

bar.tsx

export function bar() {
    console.log('bar');
}

Try moving bar

🐛 foo.ts is not shown

@mjbvz mjbvz transferred this issue from microsoft/vscode Feb 5, 2024
@RyanCavanaugh RyanCavanaugh added Bug A bug in TypeScript Help Wanted You can do this labels Feb 5, 2024
@RyanCavanaugh RyanCavanaugh added this to the Backlog milestone Feb 5, 2024
@RyanCavanaugh
Copy link
Member

Presumably this is because the selection might contain JSX tags, but we should just check for that

@DanielRosenwasser
Copy link
Member

Thanks @a-tarasyuk!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Help Wanted You can do this
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants