Innovations of TypeScript 3.0
- Lists operation support, allowing the remaining parameters to be considered generic, deriving
genericsin the type of tuples.
- The function of references to projects simplifies the work with scripts. It allows
tsconfig.jsonfiles to reference other
tsconfig.jsonfiles. In this case, TypeScript 3.0 will provide an API for linking to projects. However, for many simple applications and libraries, external tools usually aren't used. For them, the build mode was introduced.
tsc --build(or its nickname
tsc -b) takes a set of projects, builds them and their dependencies. When using this build mode, the flag must be set first and can be mapped to some other flags:
--verbose: displays each step of the build;
--dry: runs the assembly without distributing the files (this is useful with --verbose);
--clean: tries to delete files using the entered data;
--force: accelerates non-incremental reorganization of the project.
- A new type is introduced - unknown, which can now be used in cases with the description of the least accessible type in TypeScript. This is useful for APIs that literally report: "The value can be anything, you need to validate it."
- The interface of the error search function and the reasons for their occurrence have been improved. Also added support for JSX.
In June 2018 TypeScript debuted in the ranking of the top 100 TIOBE on the 93rd place.