About the Book
Your feedback is important!
You are welcome to choose to pay any amount you wish in order to access this book. If you choose not to pay anything, please repay me with your feedback. I would love a testimontial or to hear your comments, suggestions, and criticisms. Even better: if there is a change you'd like to see, clone the GitHub repository, make the changes yourself, and submit a pull request. I will recognize anyone who provides constructive feedback or changes on a special"Contributors" page in the book itself.
- What You Should Know
- Source Code Examples
- Errors, Omissions, and Contributions
- What is TypeScript?
- Writing your first TypeScript function
3. Getting Started
- Choosing your TypeScript editor
- Installing TypeScript in Visual Studio
- Installing the TypeScript Command Line Interface
- Configuring the TypeScript compiler
4. ECMAScript 2015 Features
- Optional Parameters
- Template Strings
- Let and const
- For..of Loops
- Arrow Functions
- The Spread Operator
- Computed Properties
5. Type Fundamentals
- Understanding Type Inference
- Union Types
- Function Overloads
6. Custom Types
- Defining custom types with Interfaces
- Using interfaces to describe functions
- Extending interface definitions
- Defining constant values with enums
- Anonymous Types
- Using interfaces to dynamically access object properties
- Understanding Prototypical Inheritance
- Defining a class
- Applying static properties
- Making properties smarter with accessors
- Inheriting behavior from a base class
- Implementing an abstract class
- Controlling visibility with access modifiers
- Implementing interfaces
- Creating generic functions
- Creating generic classes
- Creating generic constraints
- Organizing Your Code with Namespaces
- Using namespaces to encapsulate private members
- Understanding the difference between Internal and External Modules
- Switching from internal to external modules
- Importing modules using Require syntax
- Importing modules using ECMAScript 2015 syntax
- Loading External Modules
10. Real-World Application Development
- Generating Declaration Files
- Referencing third-party libraries
- Converting to External Modules
- Debugging TypeScript with source maps
- Implementing Class Decorators
- Implementing Property Decorators
- Implementing Decorator Factories
12. Appendix: Syntax Examples
- ECMAScript 6 Features
- Custom Types
The Leanpub 60-day 100% Happiness Guarantee
Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.
See full terms
80% Royalties. Earn $16 on a $20 book.
We pay 80% royalties. That's not a typo: you earn $16 on a $20 sale. If we sell 5000 non-refunded copies of your book or course for $20, you'll earn $80,000.
(Yes, some authors have already earned much more than that on Leanpub.)
In fact, authors have earnedover $12 millionwriting, publishing and selling on Leanpub.
Learn more about writing on Leanpub
Free Updates. DRM Free.
If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).
Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.
Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.