Skip to content

Expose isTypeAssignableTo in TypeChecker? #11728

Closed
@MeirionHughes

Description

@MeirionHughes

I would like to determine if one Type is assignable to another Type. So far I've only found the type comparison and checking functions in checker.ts, but that entire file is marked internal.

Is there a way to determine if one type is assignable to another using the exposed typescript library? A question to this effect on StackOverflow has not been answered. If not, could such functionality be added, say to TypeChecker?

Metadata

Metadata

Assignees

No one assigned

    Labels

    DuplicateAn existing issue was already created

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions