-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document correspondence between TypeScript and tslib versions #22
Comments
support of Is there a specific issue you found with different versions of the library and/or TS? |
v1.0.0 doesn't have I just happened to notice those. There might have been other changes in the other versions. I want to just be able to exactly match the behavior of TS 2.1 without |
@calebegg the use of |
I didn't mean to say that that change was a breaking one, but that there might be other breaking changes. And with our large codebase, even innocent seeming changes like that can cause issues for anyone depending on the old behavior. I just want to be able to get a version that works just like TS does on its own without having to research each change to know when it went in. |
@calebegg Fair enough. I support this request. |
There is some info in the release notes (https://github.com/Microsoft/tslib/releases)
But I agree it could be more explicit, perhaps tslib should be an optional peer dependency of typescript? npm/npm#3066 |
@frankwallis the peer dependency possibility occurred to me also but I think it may cause more problems than it solves because it rules out multi versioning. Packages depending on different versions of TSlib should be a well supported scenario. |
The compatibility between tslib and typescript library versions should be documented at least. Ideally there should be a way to validate it. We allow people to build bundles using different typescript compilers (sometimes ancient compiler versions, to target compatibility with old product releases). When these bundles are loaded, they can be dynamically linked to the same tslib library. (For example, we might have 30 bundles on our page, so we wouldn't want to load 30 copies of tslib.) If an incompatibility caused a bundle to fail, we wouldn't find out until runtime when someone did something to load that component. If needed, we could dynamically link a bundle to an older tslib to ensure compatibility -- but only if this mapping was actually documented somewhere. |
Coming in late, today we describe the versions of tslib according to their TypeScript versions:
Is that enough? Or is the answer a table somewhere saying the version which correlated to a release? |
Technically. 👍
To a casual observer, those three version mappings are so higgledy-piggledy as to raise a quiet doubt whether they are the whole story. Gussying it up with a nice-looking table might help. :-) |
Ran into this from jaredpalmer/tsdx#719 (comment) where I could only tell from the Release Notes that Is there a way to specify this in a way that is more automated or are we limited to a way that is more manual/user/docs-driven due to #22 (comment) ? |
Tagged tslib versions don't seem to correspond in any obvious way to TypeScript versions. I want to be able to confidently import the right tslib version to work with a given TS version. Maybe just a table in the readme would be enough?
The text was updated successfully, but these errors were encountered: