Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
TypeScriptの型定義が JavaScriptのバグを駆逐する
Search
Tetsuya Negishi
February 22, 2019
Programming
970
3
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
TypeScriptの型定義が JavaScriptのバグを駆逐する
Tetsuya Negishi
February 22, 2019
More Decks by Tetsuya Negishi
See All by Tetsuya Negishi
SOLIDから考える良いコンポーネントの設計原則
tetsuyanegishi
1
1.6k
React Hooksで美しいコードを書く / Writing beautiful code using React Hooks
tetsuyanegishi
0
210
React初学者が知らない コンポーネント分割テクニック
tetsuyanegishi
1
520
AWS Amplifyで作るサーバーレスバックエンド
tetsuyanegishi
3
2.1k
リアルタイムデータベース Cloud Firestore入門
tetsuyanegishi
10
9k
ブロックチェーンのマイニングとはなにか
tetsuyanegishi
1
110
スクラム開発の手法と実例
tetsuyanegishi
0
270
Other Decks in Programming
See All in Programming
komatsuna「分散システムにおけるバグ分析手法」
komatsunaqa
0
280
属人化した知識を、 AIが辿れる地図にする
pkshadeck
PRO
1
220
初めての模倣学習とVLA
natsutan
0
290
PyConJP2026_wat_Python × Signal Processing: How to Draw Pictures with Sound Using Spectrogram Art
wat
0
550
引き算の組織 ― アウトカムとAIに全振りするために辞めたこと ― / Organization by Subtraction
hirokiyamamoto14
PRO
0
310
思考垂れ流し開発 ~音声入力 × AIエージェント × 開発ハーネスによる試行錯誤~
npostring
0
330
KotlinConf Extended South Korea 2026 Keynote
l2hyunwoo
0
120
Detecting Compromised CI with eBPF and Cilium Tetragon
lizrice
0
260
異なる設計思想のフレームワークを経験して得た学び
amekuhideki
1
770
AWS Transform Customによる Spring Boot 2.xから4.xへのVerUp
satoshi256kbyte
2
110
楽しそうなつよつよエンジニアと目が死んでる僕/A brilliant engineer having a blast, and dead-eyed me.
3l4l5
2
250
Jindong: Introducing Declarative Haptics in Compose Multiplatform
l2hyunwoo
0
130
Featured
See All Featured
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
560
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
3
220
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
220
Accessibility Awareness
sabderemane
1
180
[SF Ruby Conf 2025] Rails X
palkan
2
1.3k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
900
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
11k
Making the Leap to Tech Lead
cromwellryan
135
10k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.3k
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
220
Transcript
TypeScriptͷܕఆ͕ٛ JavaScriptͷόάΛۦஞ͢Δ ࠜ؛ప
ࣗݾհ • ࠜ؛ప • ϥϯαʔζגࣜձࣾ • ৽نࣄۀ • ओʹϑϩϯτ·ΘΓ୲ •
ڵຯؔ৺ • React, Vue.js, TypeScript • αʔόʔϨε
ࠓ͢͜ͱ • ৽ϓϩμΫτʹTypeScriptΛಋೖͯ͠ΈͯͲ͏͔ͩͬͨ • TypeScriptͪΌΜͱܕఆٛ͢Ε࠷ߴ • ͋Γ͕ͱ͏TypeScript
ϥϯαʔζͷϑϩϯτΤϯυٕज़ͷมભ 2008 ~ ݱࡏ 2015 ~ ݱࡏ 2018 ~ ݱࡏ
2017 ~ 2018
ϥϯαʔζͷϑϩϯτΤϯυٕज़ͷมભ 2008 ~ ݱࡏ 2015 ~ ݱࡏ 2018 ~ ݱࡏ
2016 ~ 2018
TypeScriptΛͬͯΘ͔ͬͨ͜ͱ ܕఆٛʹΑͬͯόά͕ܹݮ ͪΌΜͱܕఆٛ͠ͳ͍ͱόάΔ
None
JavaScriptͰΑ͘ى͖Δόά
JavaScriptͰΑ͘ى͖Δόά data ʹ number ͷྻΛೖΕΔ → Ұ࣌తʹundefind͕ೖΔύλʔϯ͕͋ͬͨ → <Graph>undefindΛఆ͓ͯ͠ΒͣΤϥʔ ReactͰΓ͕ͪ
Τϥʔ
JavaScriptͰΑ͘ى͖Δόά data ʹ Object ΛೖΕΔ → Ұ࣌తʹundefind͕ೖΔύλʔϯ͕͋ͬͨ → <Graph>undefindΛఆ͓ͯ͠ΒͣΤϥʔ ReactͰͷΤϥʔ΄΅͜ͷύλʔϯͷؾ͕͢Δ
Τϥʔ TypeScriptͰൃੜ͠ͳ͍
TypeScriptͰܕఆٛͨ͠߹
TypeScriptͰܕఆٛͨ͠߹ ? → undefinedΛڐ͢
TypeScriptͰܕఆٛͨ͠߹ propsͷܕ͕ܾ·Δ
TypeScriptͰܕఆٛͨ͠߹ data number[] ͱఆٛ͞Ε͍ͯͨͱ͢Δ
TypeScriptͰܕఆٛͨ͠߹ ͜ͷ࣌Ͱ·ͩΤϥʔ → <Graph>ʹ͢ data ͕ undefinedͰ͋ΔՄೳੑ͕͋Δ
TypeScriptͰܕఆٛͨ͠߹ undefinedͷνΣοΫ Τϥʔ͕ग़ͳ͘ͳΔ
TypeScriptͰܕఆٛͨ͠߹ undefinedͷνΣοΫ Τϥʔ͕ग़ͳ͘ͳΔ
TypeScriptͰܕఆٛͨ͠߹ undefinedͷνΣοΫ Τϥʔ͕ग़ͳ͘ͳΔ όάΛະવʹ͛ͯ࠷ߴ
• ͨͩ͜͠Εܕఆ͕͖ٛͪΜͱ͞Ε͍ͯΔ߹ • ϥΠϒϥϦͰରԠ͍ͯ͠ͳ͍߹ͨ·ʹ͋Δ → any Ͱܕఆٛͯ͠ΓΔ͔͠ͳ͍ → ٯʹόάͷԹচʹͳΓ͍͢ Graph͕ܕఆٛ͞Ε͍ͯͳ͍ͱΤϥʔ͕ग़ͳ͍
Enjoy TypeScript!