|
|
|
|
|
by russellsprouts
1615 days ago
|
|
You potentially get a problem for every '.' expression. In this code: import {Something} from './file';
console.log(Something.PROP);
TypeScript doesn't know what to emit without type information. If Something is a class, then the JS will look the same. But if it's a const enum, then TypeScript has to erase the Something.PROP expression and replace it with the constant value of that enum member, since Something will not exist at runtime. |
|