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
SWC Transformerから見るTypeScript関数記述ベストプラクティス
Search
Kaito Fujimura
May 11, 2024
Technology
560
1
Share
SWC Transformerから見るTypeScript関数記述ベストプラクティス
Kaito Fujimura
May 11, 2024
More Decks by Kaito Fujimura
See All by Kaito Fujimura
iPhone Eye Tracking機能から学ぶやさしいアクセシビリティ
fujiyamaorange
0
1k
Other Decks in Technology
See All in Technology
Agentic AI時代における メルカリのAIガバナンスとガードレール実装
naoichihara
14
12k
layerx-fde-practices
cipepser
6
2.6k
TSKaigi 2026 - 型プラグインシステムの実装に使われるテクニック
teamlab
PRO
2
300
JavaScript実装の自作プログラミング言語をTypeScript実装に移行した話
keisukeikeda
1
140
Oracle AI Database@Google Cloud:サービス概要のご紹介
oracle4engineer
PRO
6
1.4k
Fラン学生が考える、AI時代のデザインに執着した突破口
husengs7
1
240
Claude Codeですべての日常業務を爆速化しよう!
minorun365
PRO
2
200
社内RAGの導入で気を付けたポイント
yakumo
2
150
データ分析基盤の信頼を支える視点と設計
yuki_saito
1
600
GitHub Copilot CLI の Rubber Duck 機能を使ってコーディングの品質をあげよう #techbaton_findy
stefafafan
2
670
Loadbalancing exporter internals
ymotongpoo
1
120
checker.tsにチキンレースを仕掛けてみた:型エラー(TS2589)が発生する境界線を求めて
hal_spidernight
1
190
Featured
See All Featured
Visualization
eitanlees
151
17k
Building an army of robots
kneath
306
46k
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
550
Embracing the Ebb and Flow
colly
88
5k
How to Think Like a Performance Engineer
csswizardry
28
2.6k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
220
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.3k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
810
Leo the Paperboy
mayatellez
7
1.8k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
400
Mozcon NYC 2025: Stop Losing SEO Traffic
samtorres
0
230
Transcript
SWC Transformer TypeScript TSKaigi 2024 @fujiyamaorange
Pay / Biome Utility Types Pick Pay for Business fujiyamaorange
TypeScript SWC Transform emit
None
None
Function Expression Arrow Function Function Declaration
None
SWC Transformer
TypeScript SWC Transform emit
SWC ~Speedy Web Compiler~ Next.js 12 Rust Babel 17 Rust
SWC (TypeScript Babel )
SWC Transformer
React 3 ※React =JSX alt data-testid
Before After
Before After alt
Before After data-testid
None
TypeScript SWC Transform emit
20.93s 22.78s 22.59s Transform 12000 React cargo test --example --
--test-threads=1 Transform
SWC Transformer
I/O
20.93s 22.78s 22.59s 17.70s 19.56s 19.31s (Transform) 3.23s 3.22s 3.28s
Transform
Transform ( )
Transform
Transform SWC fork SWC create
Transform SWC fork SWC create
( ) parse 919.22ms 959.42ms 929.58ms 931.66ms transform 56.26ms 61.25ms
58.77ms 15.72ms emit 8.75s 9.70s 9.56s 7.22s all 20.93s 22.78s 22.59s 17.70s ※
TypeScript SWC Transform emit
emit e.#mtd_name(self) mtd_name SWC AST Node SWC 200 AST Node
( : →FnDecl)
FnDecl AST emit!
emit AST Node AST emit
None
TypeScript SWC Transform emit
None
TypeScript (function) (function expression) (Arrow function expressions) SWC SWC Next.js
Compiler Trait swc_ecma_visit::VisitMut TSKaigi Canva ~Gray Purple Isometric Elements & Mockups 5G Technology Technology Presentation~ carbon