TypeScript - JavaScript you are gonna to love

TypeScript - JavaScript you are gonna to love

TypeScript, as the superset of JS uses compile-time type checkings with latest specification standard and proposals. The community chose it for thousands of projects, and it is not limited to the Angular ecosystem. It brings such powerful features like interfaces, generics, abstract classes into JS. With all-powerful tooling, it will make your JavaScript, React, Vue cleaner and less error-prone. It could involve back-end developers with Java or C# background into the client-side code. I want to show that with TypeScript you will be more productive no matter what front end technology you use!

4f0880beebecf17d29eb709246055e14?s=128

Vitalii Bobrov

April 26, 2018
Tweet

Transcript

  1. TypeScript: JavaScript you are gonna to love ❤

  2. Who am I? ๏5 years of front-end experience ๏big enterprise

    projects ๏mentor ๏public speaker ๏OSS contributor @bobrov1989 https://vitaliy-bobrov.github.io/
  3. Agenda ๏WTF TypeScript!? ๏Type system ๏How to Start? ๏Tooling ๏Integrations

  4. WTF TypeScript!?

  5. Trivial Problem

  6. JS Expression Trivia

  7. JS Expression Trivia

  8. There are NO DEFECTS if there is NO DOCs

  9. Trivial Solution

  10. jsDoc ๏Too verbose ๏Remember to update ๏No warnings of wrong

    usage
  11. TypeScript JavaScript ESNext Types

  12. Any JavaScript is VALID TypeScript

  13. ESNext

  14. WHY? ๏Easy to collaboration ๏Complex projects ๏Static analysis ๏Reduce errors

    rate ๏Easy to refactor and maintain
  15. Type System

  16. let variable: TYPE;

  17. Cheat

  18. Base Types

  19. Functions

  20. Array & Tuple

  21. DOM API

  22. enum

  23. Interface

  24. Abstract Class

  25. Union types

  26. Partials

  27. http://www.typescriptlang.org/docs/

  28. https://medium.com/@martin_hotell

  29. How to Start?

  30. REPL http://www.typescriptlang.org/play/index.html

  31. IDE & Text Editors

  32. Just change extension from .js to .ts %

  33. Tooling

  34. JavaScript checks

  35. TypeScript compiler

  36. tsconfig.json

  37. Webpack

  38. Parcel https://parceljs.org/

  39. TypeWiz https://github.com/urish/typewiz

  40. 3rd party libraries http://definitelytyped.org/

  41. Integrations

  42. Strictly typed REST API calls

  43. Just use TypeScript to write NodeJS project %

  44. Java / C# Swagger

  45. JSON Schema

  46. Thank YOU! @bobrov1989 https://vitaliy-bobrov.github.io/ https://speakerdeck.com/bobrov1989/typescript-javascript-you-are-gonna-to-love