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
1
520
SWC Transformerから見るTypeScript関数記述ベストプラクティス
Kaito Fujimura
May 11, 2024
Tweet
Share
More Decks by Kaito Fujimura
See All by Kaito Fujimura
iPhone Eye Tracking機能から学ぶやさしいアクセシビリティ
fujiyamaorange
0
930
Other Decks in Technology
See All in Technology
Beyond Prompts: Building Intelligent Applications with Genkit and the Model Context Protocol
peterfriese
0
110
ググるより、AIに聞こう - Don’t Google it, ask AI
oikon48
0
350
マーケットプレイス版Oracle WebCenter Content For OCI
oracle4engineer
PRO
3
1.3k
QAEが生成AIと越える、ソフトウェア開発の境界線
rinchsan
0
970
Copilotの精度を上げる!カスタムプロンプト入門.pdf
ismk
10
3k
ソフトウェア品質を支える テストとレビュー再考 / 吉澤 智美さん
findy_eventslides
1
920
短期間でRAGシステムを実現 お客様と歩んだ生成AI内製化への道のり
taka0709
1
240
Data Engineering Guide 2025 #data_summit_findy by @Kazaneya_PR / 20251106
kazaneya
PRO
10
2k
品質保証の取り組みを広げる仕組みづくり〜スキルの移譲と自律を支える実践知〜
tarappo
2
780
[Oracle TechNight#94] Oracle AI World 2025 Oracle Database関連フィードバック
oracle4engineer
PRO
0
250
Master Dataグループ紹介資料
sansan33
PRO
1
3.9k
龍昌餃子で理解するWebサーバーの並行処理モデル - 東葛.dev #9
kozy4324
1
140
Featured
See All Featured
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
Large-scale JavaScript Application Architecture
addyosmani
514
110k
jQuery: Nuts, Bolts and Bling
dougneiner
65
8k
[RailsConf 2023] Rails as a piece of cake
palkan
57
6k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.1k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
A Tale of Four Properties
chriscoyier
161
23k
GraphQLとの向き合い方2022年版
quramy
49
14k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.2k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
116
20k
Gamification - CAS2011
davidbonilla
81
5.5k
Designing for humans not robots
tammielis
254
26k
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