Skip to content

types are not scoped #11

@jackmellis

Description

@jackmellis
const fnA = () => {
  type Window = any;
};

const fnB = () => {
  jpex.resolve<Window>();
};

this will throw because we find the scoped type Window and then that overwrites the global Window type for the entire file

In most instances it doesn't really matter, as we only care about the name of the type. But for globals it is really unintuitive...

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions