The first TypeScript release was 10 years ago, in October 2021. Despite scepticism and the eternal search for a competitor that ends its reign, Typescript has become the choice for many developers that want to build a robust project and look beyond JavaScript. Let’s review in this article a little bit of the story and what’s to come for this strongly typed programming language.
What was Typescript created for?
TypeScript was released publicly for the first time on October 1st, 2012. That means it has been around for about ten years now. This coding language builds on Javascript and gives programmers better tooling at any scale. It had some features that made it useful to programmers, like automatic code completion. This feature is especially useful for front-end developers.
Navigation and refactoring are also key features that drew developers to this programming language. Overall, the main purpose of Typescript was to get Javascript development to scale. Microsoft has noted that its vision for what Typescript could be has not changed over the past ten years. The typed programming language was never meant to replace JavaScript and simply builds on it. TC39 implements changes to JavaScript regularly, and all these changes are automatically supported by TypeScript.
What was the situation of the web 10 years ago?
When Typescript was released, lots of developers were sceptic about it and didn’t take it seriously. Still, Microsoft was able to build a small but dedicated community of developers who were willing to experiment with this programming language. Members of the community helped to create the Definitely Typed project and worked on the issue tracker and StackOverflow. Other people wrote books and tutorials for the new language. Even with these efforts, many people didn’t see the value in using static types in a dynamically typed language.
To make sure it got the community acceptance needed, this typed programming language had to be free and open-source, and everything about it had to be done out in the open. It wasn’t supposed to be used as a distinct programming language and would instead interoperate seamlessly with JavaScript. It also had to feel like JavaScript and would evolve alongside JavaScript.
It is worth noting that JavaScript was rapidly growing in popularity in the early 2010s. It has been one of the key programming languages that made the internet dynamic. The introduction of Ajax played a great role in boosting the popularity of this programming language as developers were now able to make websites feel like native computer apps. Around the same time, various JavaScript libraries and frameworks were created. Mozilla Firefox and Google Chrome would adopt JavaScript later on, and this drove more people to the programming language. In 2012, the speed of JavaScript was doubling every nine months on average, and this made the creation of TypeScript necessary.
What effect has Typescript produced on web standards over this decade?
From the start, TypeScript had to be free, open-source, and interoperate with the existing JavaScript. This meant the programming language would primarily focus on the type system. It wouldn’t include new runtime syntax or behaviours. The team has avoided runtime syntax as much as possible. Whenever TypeScript needed a new runtime feature, they didn’t just add it to TypeScript. Instead, they work within the JavaScript standards body (TC39). This ensures that all JavaScript developers benefit from the new features.
Frameworks based on TypeScript
A number of frameworks have been built with TypeScript as a first-class citizen. The most popular one is NestJS, a framework that was inspired by the Angular module system. Its purpose is to build efficient and scalable Node.js web applications using modern JavaScript and TypeScript.
Another popular framework based on TypeScript is FeatherJS. It is used to build real-time applications and REST APIs. A benefit of this framework is that it makes it possible for developers to build prototype applications in minutes. You can make production-ready applications in just a few days. In addition to being lightweight, FeatherJS can work almost anywhere and is compatible with almost any backend technology.
The other framework built with TypeScript as a first-class citizen is LoopbackJS. This framework is highly scalable and extensible. You can use it to build microservices and APIs. With LoopbackJS, you can create modern applications with little to no coding. The fourth version of this framework was released in 2018 by IBM, and it has a moderate learning curve.
AdonisJS is another great Typescript framework that allows developers to write web apps with less code. It was inspired by Laravel and uses ideas that are similar to those of Dependency Injection and Providers. This framework has a very convenient folder structure that helps to keep the code organized and clean. You can even modify the structure to suit your needs. AdonisJS is focused on developers’ speed, stability, and ergonomics.
TsED framework was also created around TypeScript. It was built on top of Express.js and Koa, and it makes it easy and quick to build out your server application. The framework brings structure to Express apps and is especially useful for large-scale web development. Like other popular frameworks, this one has great support. Any issue opened will get resolved or responded to quite fast.
ECMA TC39 and how TypeScript influenced it
ECMA is a standards organization that facilitates the use of information and communication technology. It influences the environments where technology is applied and encourages the correct use of the standards. This body standardizes JavaScript using the ECMAScript specifications. Within ECMA, there is the Technical Committee number 39 or TC39. This committee performs the following roles:
- It maintains and updates standards for the ECMAScript programming language.
- It creates and updates standards for libraries that enhance the capabilities of ECMAScript.
- It helps to contribute certain standards to the ISO/IEC JTC 1 committee.
- It creates test suites that can verify the proper implementation of the set standards.
- It examines and checks proposals for additional technologies.
Only members of TC39 can create proposals for changes to ECMAScript. Proposals that go through the five stages are included in the next revision of ECMAScript. These changes are used to maintain and evolve the definition of JavaScript. Although only members of the committee can create and pass proposals, the developer community is welcome to offer feedback on existing proposals and language feature ideas.
It is worth noting that TypeScript generally supports new JavaScript proposals that are supported by TC39. This happens even before browsers fully support the changes.
What we can expect in the future from Typescript?
Millions of developers now use TypeScript, and it consistently ranks among the ten most popular programming languages. While it is used along with JavaScript, this language has experienced a lot of success individually. Many users of the language report that they love using TypeScript. It is becoming the most common choice for new JS commercial projects. Since this typed programming language was meant to work with JS, it will never replace JavaScript. It will always build on JS as a solid foundation. It is expected that TypeScript will keep growing in popularity for the foreseeable future as it offers many benefits to developers. It doesn’t have a lot of competition and offers a great web development experience. It is also expected that TypeScript will enjoy high adoption rates among new open-source projects.
Conclusions: alive and kicking 10 years after release
TypeScript was released in 2012 and is now ten years old. Microsoft has reported that this programming language has surpassed their expectations as it has consistently ranked among the top ten most loved languages. Its success can be credited to the efforts of the community through the years. Members of the community have been involved in writing tutorials for the language, and they also helped out with the issue tracker and StackOverflow.
Even though many people were sceptical of the use of static types in JS, TypeScript has been able to stand the test of time. From the beginning, this language was meant to build on JS. This is why the team has avoided adding new runtime syntax and behaviours. Over the years, many frameworks have been built around TypeScript. Some of the best ones are JestJS, FeatherJS, LoopbackJS, AdonisJS, and Ts.Ed.