I have recently been introduced to TypeScript through school. I come from a Java background, so it has been my strong suit or a safe point regarding coding. When I first tried TypeScript, the parallels to Java were super clear, especially in its syntax and the clarity it provides when defining variables and function signatures. But TypeScript isn’t just “JavaScript with types.” It blends how dynamic JavaScript is with a powerful type system, giving coding with it much more freedom.
This essay will reflect on my experiences with TypeScript, explain why I find it pleasant to use, and share thoughts on the “athletic software engineering” approach (with some specific reference to WODs) that has shaped my learning process 2 weeks into my 4th semester as Computer Science Major at the University of Hawaii at Manoa. Throughout the essay, I will highlight what I’ve learned about TypeScript’s functionality, discuss its value from a software engineering standpoint, and attempt to explain how it can enhance productivity and code quality.
I’ve always enjoyed writing Java, and TypeScript provides a similar style while feeling much more simple and flexible. Unlike basic JavaScript, TypeScript’s ability to specify variable types makes me feel much more secure while coding in the same way I hate doing loops in Python and prefer Java. This means fewer runtime surprises. For example, if I declare a variable as a string, the compiler ensures I don’t accidentally assign it a numeric value later.
TypeScript’s benefits go beyond type safety. One feature I’ve learned to appreciate is type inference. TypeScript can infer a variable’s type based on how it’s initialized, which cuts down on length declarations. For instance:
```typescript // TypeScript infers 'message' as a string let message = "Hello, TypeScript!"; ```
Without me explicitly stating that the message is a string, TypeScript infers it from the initial assignment. This balances the best of both worlds: strong typing when I need it and easy, readable code when I don’t.
Before starting to learn TypeScript, I knew a fair amount of JavaScript. I knew many ES6 features like arrow functions, template literals, and destructuring. Despite this, going through lessons that explicitly connected JavaScript to TypeScript helped me understand how TypeScript builds on modern JavaScript while adding types, interfaces, and other enhancements.
One new thing I learned about TypeScript’s functionality is its support for advanced types, such as union types and interfacenumbers ,allow you to define more complex object shapes. As someone with mainly Java experience, I feel these features are vevery comfortable with these features. They sometimespressive than Java at times, particJava’sescribing objects or functions that may behave differently depending on the context.
In my opinion, TypeScript is an excellent choice from a software engineering standpoint. It has much cleaner code, reduces bugs early through compile-time checks, and makes refactoring far less risky. In large-scale projects, having explicit types means:
Beyond the language, I’m also a big fan of the athletic software engineering approach. In my experience, the best way to learn any technical topic is by reading a little bit and then just practicing till I feel confident so I understand what I don’t know and work out the kinks of these topics in practice, not just in theory. Athletic software engineering forces you to tackle exercises known as WODs (Workouts of the Day) within a certain amount of time. The benefits of this approach are:
One of the highlights of athletic software engineering is that it also complements the flipped classroom environment. By working on materials at home, I learn what I understand versus what I don’t know. Then, during class, I focus on clarifying those parts I am stuck on. This structure:
Ultimately, this style keeps me motivated and ensures I work toward practical competency rather than memorizing facts for a test when I probably cannot even do those in practice.
In summary, TypeScript has become one of my favorite languages because it combines Java’s type safety with JavaScript’s flexibility. Its features—such as type inference, advanced type definitions, and powerful tooling—make it an excellent choice for large-scale software engineering projects. Combining TypeScript with the athletic software engineering approach has been enjoyable and practical from a personal learning standpoint. I’m more confident, less stressed, and excited to keep building my expertise by practicing and writing real-world applications.
Anyone contemplating investing time in TypeScript and athletic software engineering should do so.