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" quickfix does not work for import * as ... #27778

Open
lucacasonato opened this issue Jan 22, 2025 · 1 comment
Open

"Move to new file" quickfix does not work for import * as ... #27778

lucacasonato opened this issue Jan 22, 2025 · 1 comment
Assignees
Labels
lsp related to the language server tsc related to the TypeScript tsc compiler

Comments

@lucacasonato
Copy link
Member

Version: Deno 2.1.6

// main.ts
import * as a from 'data:application/json,{"a":1}' with { type: "json" };
const y = a;

When you try to execute the "Move to a new file" quick fix in VS Code in the main.ts file, the LSP fails to respond to the codeAction/resolve request.

It works if the file referenced from the import does not exist. It fails if it does exist (data url, local file, npm specifier all fail).

@lucacasonato lucacasonato added lsp related to the language server tsc related to the TypeScript tsc compiler labels Jan 22, 2025
@lucacasonato
Copy link
Member Author

This also turns out to be the root cause for the live share issue - Live Share is eagerly calling codeAction/resolve, whereas without liveshare this is only triggered when the user actually triggers the code action.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lsp related to the language server tsc related to the TypeScript tsc compiler
Projects
None yet
Development

No branches or pull requests

2 participants