bug: TypeScript is not an ECMAScript superset post-ES2015
github.com
github.com
> import { a } from "./a"
Seems to be the issue, maybe something about missing an extension.
> Bearing this in mind, the last version of ES for which TypeScript was a superset would be ES5 (2009), before the introduction of ES modules.
This certainly matters to those writing ts -> js transpilers. As far as I care, it doesn't matter if the split happens at ES5 or ES2015 as long as the transpiled output works.
The fact that this detail is being raised seems like an indication of how well it conforms to being a superset, unlike CoffeeScript's "It's just JavaScript." assertion.
But I think that TS is still a superset of JS, even with this import thing.
Because every valid JS file is valid TS file. To me that seems to confirm to definition of superset:
A set A1 is a superset of another set B1 if all elements of the set B1 are elements of the set A1.