Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
LT駆動開発04 5分では分からないTypeScriptのなんとか
Search
Kazuya Matsubara
June 07, 2014
Programming
1.1k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
LT駆動開発04 5分では分からないTypeScriptのなんとか
LT駆動開発 04で発表したLT資料です。
「5分では分からないTypeScriptのなんとか」
Kazuya Matsubara
June 07, 2014
Transcript
12 slides
5分では分からない TypeScriptのなんとか 2014/06/07 LT駆動開発04 @Toro_kun
module SelfIntroduction { export class Me extends
Person { private name: string = ”松原和也”; private twitterId: string = ”@Toro_kun”; private community:string[] = [ ”⽇日本Androidの会中国⽀支部@staff”, ”GDG中国@staff”, ”JSers' Cafe ZERO@owner” ]; } }
TypeScriptとは Ê 静的型付け⾔言語 Ê カターンゼンッ Ê 2014年年04⽉月02⽇日にversion 1.0がリリース
Ê JavaScriptのスーパーセット Ê コンパイルしてJavaScriptを⽣生成 Ê altJS
altJS ⾔言語 設計/開発 登場時期 影響を受けた⾔言語 CoffeeScript Jeremy Ashkenas, et
al. 2009 JavaScript, Python, Ruby, Haskell TypeScript Microsoft 2012 JavaScript, Java, C# Haxe Haxe Foundation, Nicolas Cannasse 2005 ActionScript, OCaml Dart Google 2011 Java, C++, JavaScript, CoffeeScript, Go JSX DeNA 2012 JavaScript, ActionScript モダンな⾔言語でHTML5を開発しよう! 俯瞰して理理解するaltJSの⽐比較 (前篇 – TypeScript, CoffeeScript, Haxe) http://html5experts.jp/clockmaker/2183/ より
TypeScriptの何がいいのか Ê コンパイル時に型の整合性チェックが⾏行行われる Ê IDE等で補完機能を使える Ê JavaScriptの書き⽅方をしても動く
Ê (この部分は静的型付けは損なわれるが・・・) Ê TypeScriptとほぼ⼀一対⼀一で対応するJavaScriptに変換 Ê ⽣生成されたJavaScriptの可読性がよい
TypeScriptの開発環境 Ê Visual Studio 2013、2012(WIndows) Ê WebStorm Ê
Eclipse + Eclipse TypeScript plug-‐in Ê Sublime Text + T3Sモジュール Ê Vim + TypeScriptプラグイン Ê Emacs + TypeScript拡張
つかってみました
enum TypeScript enum sample { a = 1,
b, c = 4, daa } JavaScript sample; (function (sample) { sample[sample["a"] = 1] = "a"; sample[sample["b"] = 2] = "b"; sample[sample["c"] = 4] = "c"; sample[sample["daa"] = 5] = "daa"; })(sample || (sample = {}));
enum (TypeScript)
enum (JavaScript)
⽂文字列列を設定すると怒怒られる けどコンパイルしてくれる なんてツンデレさんなんでしょう
終
More Decks by Kazuya Matsubara
See All by Kazuya Matsubara
LT駆動開発09 - Creative Commonsについてゆる〜く調べてみた
torokun
1
980
すごい合同勉強会2014 in 広島 懇親会LT
torokun
0
520
LT駆動開発08 - 無限のディスク領域を手に入れよう(妄想編)
torokun
0
140
やめよう「なるはや」
torokun
1
210
DevLOVE広島 第1回 その改善いつするの?
torokun
0
870
LT駆動開発 03 写真を趣味にしてから学んだこと
torokun
0
750
LT駆動開発 02 一発ネタ
torokun
0
1.1k
LT駆動開発 01 gulp入門にもならない何か
torokun
2
590
Other Decks in Programming
See All in Programming
眠らない開発チームの作り方
biwakonbu
0
180
Kawaiicon: Kubernetes, it's no longer cool, but let's secure it anyway!
barnbarn
0
150
AppFunctionsの内部実装を紐解く
hiroaki404
1
130
AIコーディングをセッションで終わらせない: PHPライブラリ開発におけるコンテキスト承継設計
ickx
0
110
Proxmox x Talos Linux x Terraform で実現するなんかいい感じの Kubernetes クラスタ / A Sleek Kubernetes Cluster Powered by Proxmox, Talos Linux, and Terraform
nnaka2992
0
320
作れるエンジニアから、価値を届けるエンジニアへ
ryunakayama
1
1.3k
テストだけで見つかる? Rubyでつくるメソッド発掘器
izawa
0
170
RaspberryPi 5で軽くはじめるk3sとtailscaleを用いたホームサーバー構築 (1)
nasum
0
450
ローカルLLMの基本と近況 2611 / Local LLM basics and recent situation 2611
kishida
3
680
flutter_test のその先へ — Flutter アプリの LLM 機能に「評価」という品質保証を
kosukesaigusa
0
210
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
210
AIが実装を担う時代の「技術設計」と「チームマネジメント」
kamina_zzz
2
470
Featured
See All Featured
A designer walks into a library…
pauljervisheath
211
25k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
35k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
350
4 Signs Your Business is Dying
shpigford
187
23k
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3.3k
Building Adaptive Systems
keathley
44
3.3k
Principles of Awesome APIs and How to Build Them.
keavy
128
18k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
620
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
480
Into the Great Unknown - MozCon
thekraken
41
2.8k
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
1
620