-
Notifications
You must be signed in to change notification settings - Fork 13k
Closed
Labels
Milestone
Description
Bug Report
π Version & Regression Information
This is the behavior in every version I tried: v3.3.3 and v4.9.4
β― Playground Link
Playground link with relevant code
π» Code
let a: number;
a = ''; // Type 'string' is not assignable to type 'number'.
let exports: number;
exports = ''; // Everything is fine
π Actual behavior
Variable named exports
is not type-checked.
π Expected behavior
Either the variable exports
should be type-checked or the variable should not be allowed to be named exports
(as far as I could tell exports
is not a reserved word).
RyanCavanaugh, Tobias-Scholz, MisterrHappy and migueljteixeirasky