<!--DEBUG:--><!--DEBUG:dc3-united-states-software-in-english-pdf-2--><!--DEBUG:--><!--DEBUG:dc3-united-states-software-in-english-pdf-2--><!--DEBUG-spv-->{"id":739586,"date":"2017-11-03T19:01:00","date_gmt":"2017-11-03T17:01:00","guid":{"rendered":"http:\/\/nhub.news\/?p=739586"},"modified":"2017-11-04T02:41:07","modified_gmt":"2017-11-04T00:41:07","slug":"typescript-practical-introduction-part-1","status":"publish","type":"post","link":"http:\/\/nhub.news\/de\/2017\/11\/typescript-practical-introduction-part-1\/","title":{"rendered":"TypeScript Practical Introduction, Part 1"},"content":{"rendered":"<p style=\"text-align: justify;\"><b>A web development expert gives an introduction to the TypeScript language, and goes over how to install it, get a TS project up and running, and a few features.<\/b><br \/>\nIn this article, we are going to learn the basic features of TypeScript through practical examples. We&#8217;ll start with a small introduction to TypeScript, then we are going to create a TypeScript project and use its features to learn the language in practice.<br \/>TypeScript is a programming language, built by Microsoft, that extends JavaScript. The language has been built as an open source project, licensed under the Apache License 2.0, so the developer community can use it freely. Among its features, a remarkable one is that TypeScript brings type safety to one of the most flexible, dynamic programming languages around, JavaScript. This characteristic enables developers to be very productive even on large codebases by introducing and facilitating tools and practices like static checking and code refactoring.<br \/>Besides enabling developers to check the correctness of their code before running it, TypeScript also brings to the table the state of the art features of JavaScript. That is, with TypeScript we can take advantage of the latest features of JavaScript, like those introduced by ECMAScript 2015, and features that are still under consideration (e.g. decorators). As the developers of TypeScript knew that applications written in the language would face a wide variety of environments (i.e. JavaScript engines), they made it easy to compile and transpile TypeScript to different targets, like ECMAScript 3 and above.<br \/>To compile and transpile TypeScript into JavaScript, we need to install the command-line compiler. As this compiler is, in fact, a Node.js program, we first need to install Node.js and NPM on our environment. After that, we can install the compiler as a Node.js package:<br \/>This will make the tsc (TypeScript Compiler) command available globally on our machine. To test the installation, let&#8217;s create a simple TypeScript file called index.ts with the following code:<br \/>Then let&#8217;s use the compiler to transform it to JavaScript:<br \/>This will generate a new file called index.js with the exact same code of the TypeScript file. To execute this new file, let&#8217;s use Node.js:<br \/>Although the compiler did nothing else besides create a JavaScript file and copy the original code to it, these steps helped us to validate that our TypeScript installation is in good shape and ready to handle the next steps.<br \/>To create a TypeScript project, everything that we need is in a tsconfig.json file. The presence of this file in a directory denotes that this directory is the root of a TypeScript project. This file, among other things, instructs the compiler on which files to compile, which files to ignore, and what environment to target (e.g. ECMAScript 3).<br \/>To create our first TypeScript project, let&#8217;s create a new directory and add the TypeScript configuration file to it:<br \/>As TypeScript can aim different environments (like ECMAScript 3 or ECMAScript 2015) and can be configured to validate different things (like implicit any), we use the tsconfig.json file to adjust the compiler to our needs. In our practical introduction to TypeScript, we will create a small program that deals with tasks and stories and that runs on our terminal, through Node.js, to help us understand the concepts.<br \/>Node.js is based on Chrome V8, one of the most up-to-date JavaScript engines available. Version 6 of Node.js ships with a Chrome V8 version capable of supporting 95% of the ECMAScript 2015 specification, as shown by Node Green, while version 8 is capable of supporting 99%. In respect to ECMAScript 2017, both versions support 23% and 73% of the specification, respectively. Therefore, the best choice is to configure our project to be compiled to ECMAScript 2015, which will enable users with Node.js 6 and 8 to run our program without trouble.<br \/>Besides configuring the compiler to target ECMAScript 2015, we will also configure four other characteristics:<br \/>We will also tell the compiler to process files under .\/src, a directory that we will create to which we will add our TypeScript source code. To perform these configurations, let&#8217;s open the tsconfig.json file and add the following content to it:<br \/>The options used in the configuration file above are just a small subset of what TypeScript supports. For example, we could instruct the compiler to handle decorators, to support jsx files, or even to transpile pure JavaScript files. The official website contains a list of all the options available on TypeScript, but below is an explanation of a few commonly used options:<br \/>Now that we understand how to bootstrap a TypeScript project and configure the compiler, let&#8217;s start learning about the features provided by TypeScript. Although the features that we are going to cover here (and a few more) are thoroughly explained in the TypeScript handbook, this article will focus on a more practical approach. We will learn the basic concepts of the most important features and put them to work together.<br \/>Before creating anything that matters, we need to learn about the most important features of TypeScript: types, variables, and functions. TypeScript became popular over the last couple of years because it enables developers to define strongly typed variables, parameters, and return values while still using JavaScript (which by its nature is weakly typed and extremely flexible). For example, developing in JavaScript, the following code is perfectly valid:<br \/>Running it on Node.js, or on any browser for that matter, would output thirty two1 without generating any warning. Nothing new here, it&#8217;s just JavaScript behaving as flexible as always. But, what if we want to guarantee that the addOne function accepts only numbers when called? We could change the code to validate the parameter during runtime&#8230; or we could use TypeScript to restrict that during compile time:<br \/>Now, using the TypeScript compiler to generate JavaScript will produce an error saying:<br \/>This is the most valuable feature of TypeScript. Based on this feature amazing tools and IDE integrations can be created to improve tasks like code refactoring. Being able to define types during design time helps us avoid mistakes like passing the wrong variable type to functions.<br \/>String and number are two of the basic types that TypeScript supports. Besides these types, TypeScript also supports:<br \/>These types enable us to create solutions to whatever problem we face. With them, we can develop code that guarantees that the correct types are being passed around and, if we need to represent more complex entities, we can define classes that contain any arbitrary number of typed variables (as we will see in the next section). To provide an overview of what TypeScript makes possible, let&#8217;s take a look at the following code:<br \/>The first step executed by the code above creates a type (tuple) that accepts three objects: a number, a string, and a boolean. This tuple represents a ranking where the number is the position, the string is the name of the person in that position, and the boolean indicates whether the player has finished the game or not. In the second step, we define five typed variables to hold:<br \/>Steps three and four use these variables to create two rankings and to push them to the array of rankings ( hallOfFame). Step five defines a function that iterates over an array of rankings and prints them. The last step simply calls the function defined in the previous step passing the array of rankings ( hallOfFame). Note that all these steps were defined in such a way that the compiler is able to validate everything before runtime. For example, trying to push something else other than a tuple that contains exactly a number, a string, and a boolean to hallOfFame would generate an error. Another example is that trying to capture the return value of a call to printRankings would also generate an error since this function explicitly defines that it returns nothing (: void).<br \/>To learn more about the basic types of TypeScript, take a look at the documentation. The official website also contains a section that talks about advanced types, like the type that we declared in the first step of the example above.<br \/>Another feature that TypeScript inherits from ECMAScript 2015 is the support for modules. Modules in both languages (JavaScript and TypeScript) are a way to encapsulate code into their own scope. That is, when we create a module and add some code to it, we are not letting anything (like variables, functions, etc.) escape silently. Everything that we want to provide externally needs to be explicitly exported by our module and explicitly imported by other modules\/scripts.<br \/>For example, if we change the code in the previous section by adding the following line:<br \/>We are then able to import the printRankings function and the RankingTuple type definition on other modules\/files to use them. Throughout this article, we are going to define and export multiple classes and import them into other files. As each of these classes will be defined in their own files, they can be considered separate modules. To learn more about modules, check out the official documentation.<br \/>Tune in next time when we&#8217;ll discuss TypeScript classes, interfaces, decorators, and iterators!<\/p>\n<div id=\"td_post_ranks_tmp\" class=\"td-post-comments\" style=\"vertical-align: middle;display:none;\">\n<div style=\"float: left;\">Similarity rank: 2.1<\/div>\n<div style=\"float: left; padding-left: 10px;\">Sentiment rank: 1.6<\/div>\n<div style=\"float: left;\"><img width=\"20px\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEsAAABMCAIAAACqKd0FAAAARXRFWHREZXNjcmlwdGlvbgBDUkVBVE9SOiBnZC1qcGVnIHYxLjAgKHVzaW5nIElKRyBKUEVHIHY2MiksIHF1YWxpdHkgPSA5MAotqor\/AAAALHRFWHRDcmVhdGlvbiBUaW1lAFNhdCAxNSBPY3QgMjAxNiAxODo0OTo0NiArMDIwMNJda1EAAAAHdElNRQfgCg8PNQf\/Sqn9AAAACXBIWXMAAB7CAAAewgFu0HU+AAAABGdBTUEAALGPC\/xhBQAAH75JREFUeNqte3usZVd533rt1znnvmfGMzY2YxvXLm4wplAbC2yCUBucgqKS1rShaRSRxAhRWkuRUSW3jZK4SfiPhLSqWtrYfUQIFcUhLW3AERWoAjcPOYztOGNmxthjz525r\/Pcj\/Xo7\/vWPuee+5rBqNvHZ87dZ5+11\/f6fb\/vW2vLEGpBh+Z3JWZH4HcZ\/\/CzdysM3o0Y8TUTPr0ipHReaS2c9HydlPTLiq\/k34Z0dxjF\/7iELgl0i8A3d2IjiCBFQbMJXbq5nPCPgg\/eyR7\/mGabBR6hyuk9n843BHHYYcQbPMK85JI1IukPHWcZHO6kVcoqCrWr8S0OFYIkqeXuQKrVI2br+RvJV1jh1EzRuBmf1FK7NzrR6SFDmP+tuuYPnGhI0y7FnRVLCwt4j\/NCK3iCh4Sy7rMwy\/RtE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djYMYEkwdFWb2epCPCNY9TlfTnB+mlKDTL2q828hOx6PXyEhLScxOdhY6Kg0ujp4eUh\/POow8Tu6aF9YaY5vPIo232yBDkiI5IjjY8LkzR9w9stUuVArXJDdVZD8jjqyQduXrX1DtuwxTYRN79qTkIFZ2+qGITukRAJyQacZIm6xFHYbgIslFs9on2WbI+LHi5ha6KDssndAoqfAZ1y8DAXmYLmR1tqadeU5ZTL9vTEfqh1yF2C9lkNsJbDJGSozqOEPAKtdsm4XqKSmIbpGpOwwjWzSzWb5mHYsVfCvc9+7aIL1dUUjTEy2cfldF8d\/qDHnWhHCwNsI0nFBT92UrNIJJjylh9R49qHtaOZwbUStk94qN1o1CSPVAVzMH4qTKWs3oTfUxZA8QrRbEGp3QNEPGxXPDUni\/uBn12T7eJTbBZA92xPVoKK9VXcqiamT6q1O3oC36J1ALW7nuDbebTRyLIRSisdn7lj\/sVnhIxc7AhzzWH+oWY0B58YDbtNm+lj1i1XMPystW2vkrOlTTffjpX8IE5sRZC2243H7KvtJufdO858NeqOPDDeS0yJGHlPZFez6+UPDjNiFocxwR\/8OhyxOD6ff2Jyaf2DDTrdX8z7S1uf53WFOQlDVKScf0peRu\/l0dTcjWQck8+\/AdnaEZwv5+Ydm\/xxPewgAvlDh9iLw0rsXdhWcv6vMDfWngf+Z\/eVc568r8s0u37P6oOfP7P7cMIh9eGhuLRXwh\/EyPuvOcqh5CHX7+mRiaPTwHyX7MDtDonD2ehyuqyvDlwa9XrwcVU1Syp7Zjk\/m33\/HqaJMA\/hYraLfPcZ30PT9V7rHXnM6sM37N9XUdu1HiD\/YW5xzefujzr+H6PoJNk51hMyAAAAAElFTkSuQmCC\" \/><\/div>\n<\/div>\n<p><script>\n\/*jQuery(function() {\nvar mainContentMetaInfo = '.td-post-header .meta-info';\nvar tdPostRanks = '#td_post_ranks';\nif (jQuery(tdPostRanks).length) {\n    var tdPostRanksHtml = jQuery(tdPostRanks).get(0).outerHTML;\n    if (typeof tdPostRanksHtml != 'undefined') {\n        jQuery(tdPostRanks).remove();\n        jQuery(mainContentMetaInfo).append(tdPostRanksHtml);\n    }\n}\n});*\/\n<\/script><span>\u00a9 Source: <a href=\"https:\/\/dzone.com\/articles\/typescript-practical-introduction-part-1?utm_medium=feed&amp;utm_source=feedpress.me&amp;utm_campaign=Feed%3A+dzone\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/dzone.com\/articles\/typescript-practical-introduction-part-1?utm_medium=feed&amp;utm_source=feedpress.me&amp;utm_campaign=Feed%3A+dzone<\/a><br \/>\nAll rights are reserved and belongs to a source media.<\/span><\/p>\n<script>jQuery(function(){jQuery(\"#td_post_ranks\").remove();});<\/script><script>jQuery(function(){jQuery(\".td-post-content\").find(\"p\").find(\"img\").hide();});<\/script>","protected":false},"excerpt":{"rendered":"<p>A web development expert gives an introduction to the TypeScript language, and goes over how to install it, get a TS project up and running, and a few features. In this article, we are going to learn the basic features of TypeScript through practical examples. We&#8217;ll start with a small introduction to TypeScript, then we [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":739585,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[93],"tags":[],"_links":{"self":[{"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/posts\/739586"}],"collection":[{"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/comments?post=739586"}],"version-history":[{"count":1,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/posts\/739586\/revisions"}],"predecessor-version":[{"id":739587,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/posts\/739586\/revisions\/739587"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/media\/739585"}],"wp:attachment":[{"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/media?parent=739586"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/categories?post=739586"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/nhub.news\/de\/wp-json\/wp\/v2\/tags?post=739586"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}