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 export value on deconstruction #119

Open
yiliang114 opened this issue Jul 7, 2023 · 3 comments
Open

Cannot export value on deconstruction #119

yiliang114 opened this issue Jul 7, 2023 · 3 comments
Assignees
Labels
feature-request Request for new features or functionality @vscode/l10n-dev
Milestone

Comments

@yiliang114
Copy link
Contributor

For example, the following two cases cannot be scanned by l10-dev:

import * as vscode from 'vscode';
const {
  l10n: { t },
} = vscode;
const { l10n: aaa } = vscode;

console.log(t('Hello {0}', ['yiliang114']));
console.log(aaa.t('Hi {0}', ['yiliang114']));
@TylerLeonhardt
Copy link
Member

Yeah we support:

import { l10n } from 'vscode';
import { l10n: aaa } from 'vscode';

which you can see in the tests. but not what you're talking about here. This is because we do this statically (we have to) and our tree-sitter query needs to be expanded to support this syntax.

@TylerLeonhardt TylerLeonhardt added feature-request Request for new features or functionality @vscode/l10n-dev labels Jul 7, 2023
@TylerLeonhardt TylerLeonhardt self-assigned this Jul 7, 2023
@TylerLeonhardt TylerLeonhardt added this to the Backlog milestone Jul 7, 2023
@yiliang114
Copy link
Contributor Author

Yeah we support:

import { l10n } from 'vscode';
import { l10n: aaa } from 'vscode';

which you can see in the tests. but not what you're talking about here. This is because we do this statically (we have to) and our tree-sitter query needs to be expanded to support this syntax.

Uh-huh, I'm also used to looking for all the ways to use it from unit tests.

I think you have added a label named Backlog, which means this feature will be added later?

@TylerLeonhardt
Copy link
Member

Backlog means we would like to do this but it's not currently being worked on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Request for new features or functionality @vscode/l10n-dev
Projects
None yet
Development

No branches or pull requests

2 participants