JavaScript & TypeScript

JavaScript is an object-oriented computer programming language commonly used to create interactive effects within web browsers. It is a core technology of the World Wide Web, alongside HTML and CSS. JavaScript enables you to create dynamically updating content, control multimedia, animate images, and much more. It is the third layer of the layer cake of standard web technologies, two of which (HTML and CSS) we have covered in much more detail in other parts of the Learning Area.

TypeScript is a syntactic superset of JavaScript which adds static typing. This means that TypeScript adds syntax on top of JavaScript, allowing developers to add types. TypeScript being a “Syntactic Superset” means that it shares the same base syntax as JavaScript, but adds something to it. TypeScript allows specifying the types of data being passed around within the code, and has the ability to report errors when the types don’t match. For example, TypeScript will report an error when passing a string into a function that expects a number. JavaScript will not.