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

Isolated declarations quick fix explicitly prints out default type arguments #58449

Open
DanielRosenwasser opened this issue May 6, 2024 · 0 comments
Labels
Domain: Isolated Declarations Related to the --isolatedDeclarations compiler flag Experience Enhancement Noncontroversial enhancements Help Wanted You can do this Suggestion An idea for TypeScript
Milestone

Comments

@DanielRosenwasser
Copy link
Member

// @declaration: true
// @isolatedDeclarations: true

export interface Foo<T, U = T[]> {
}

export function /**/foo(x: Foo<string>) {
    return x;
}

Request a quick fix at /**/.

Current:

Add return type 'Foo<string, string[]>'.

Expected:

Add return type 'Foo<string>'.
@RyanCavanaugh RyanCavanaugh added Suggestion An idea for TypeScript Help Wanted You can do this Experience Enhancement Noncontroversial enhancements labels May 6, 2024
@RyanCavanaugh RyanCavanaugh added this to the Backlog milestone May 6, 2024
@weswigham weswigham added the Domain: Isolated Declarations Related to the --isolatedDeclarations compiler flag label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Domain: Isolated Declarations Related to the --isolatedDeclarations compiler flag Experience Enhancement Noncontroversial enhancements Help Wanted You can do this Suggestion An idea for TypeScript
Projects
None yet
Development

No branches or pull requests

3 participants