Upgrade to Pro — share decks privately, control downloads, hide ads and more …

TypeScriptで型安全に入門したい

atsuco
January 15, 2020

 TypeScriptで型安全に入門したい

2020/01/15 Mercari x Merpay Frontend Tech Talk vol.4 での資料です
https://mercari.connpass.com/event/83613/

途中にある参考資料はこちら
Programming TypeScript: Making Your JavaScript Applications Scale
https://www.amazon.co.jp/dp/1492037656

合法TypeScript
https://uncle-javascript.com/valid-typescript

実践TypeScript ~ BFFとNext.js&Nuxt.jsの型定義~
https://www.amazon.jp/dp/483996937X

atsuco

January 15, 2020
Tweet

More Decks by atsuco

Other Decks in Programming

Transcript

  1. +4ͱ54ͷܕͷҧ͍ +BWB4DSJQU 5ZQF4DSJQU ܕ෇͚ํ๏ ಈతܕ෇͚ ίʔυΛ࣮ߦͯ͠ܕΛ൑ผ͢Δ ੩తܕ෇͚ ܕΛίʔυ্Ͱࢦఆ͢Δ ܕͷࣗಈม׵ ͞ΕΔ

    ͞Εͳ͍ UZQFDIFDLFSͷ λΠϛϯά ࣮ߦ࣌ ίϯύΠϧ࣌ Τϥʔͷ ൃ֮λΠϛϯά ࣮ߦ࣌ ίϯύΠϧ࣌
  2. // Ҿ਺ͷܕΛnumberʹݻఆ͢Δ function squareOf (n: number) { return n *

    n; } squareOf(10); // 100 squareOf('string'); // error