Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Are Typescript versions backwards compatible?

Tags:

typescript

Will there be breaking changes to current TS code that I have already written in future releases of TS? I am on version 0.8.3 right now.

like image 407
Paul Mendoza Avatar asked Apr 13 '13 02:04

Paul Mendoza


1 Answers

Yes (depending on what you've written, of course). TypeScript uses Semantic Versioning; until version 1.0 is declared, breaking changes are possible. For example, the syntax used for enum will be changing between 0.8.3 and 0.9.0, and there may be more changes between 0.9 and 1.0, though those will be kept to an absolute minimum. After 1.0, however, you can expect zero breaking changes (for practical purposes -- no guarantee that degenerate code that 'accidently' compiled due to a bug will remain so).

Our experience moving over some teams with very large codebases from 0.8.3 to 0.9.0 has been that the majority of post-0.8.3 'breaking' changes are just bugs that have been fixed in code that you wouldn't have expected to compile in the first place. In any type system there will be some disagreement about what a 'bug' really is, but code that is legal according to the 0.8.3 spec will almost certainly work in 0.9.

like image 198
Ryan Cavanaugh Avatar answered Sep 28 '22 15:09

Ryan Cavanaugh