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
Immutable.js with Flowtype
Search
Takumi Ohashi
July 14, 2017
0
7.1k
Immutable.js with Flowtype
Takumi Ohashi
July 14, 2017
Tweet
Share
More Decks by Takumi Ohashi
See All by Takumi Ohashi
freee Tech Night #2 会計freee 7年目のフロントエンド開発
tohashi
1
7.9k
How to control loading state in React
tohashi
2
190
フロントエンドのモダン化とJavaScriptモジュールの 依存解決
tohashi
8
2.9k
Featured
See All Featured
Building an army of robots
kneath
302
43k
Facilitating Awesome Meetings
lara
50
6.1k
A designer walks into a library…
pauljervisheath
203
24k
[RailsConf 2023] Rails as a piece of cake
palkan
52
4.9k
Documentation Writing (for coders)
carmenintech
65
4.4k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
250
21k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
364
24k
The Invisible Side of Design
smashingmag
298
50k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
Bash Introduction
62gerente
608
210k
How to train your dragon (web standard)
notwaldorf
88
5.7k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
Transcript
Immutable.js with Flowtype @_tohashi
୭ • Takumi Ohashi • twitter: @_tohashi • GitHub: @tohashi
• ϑϦʔʢגʣͷΤϯδχΞ
ίϯϙʔωϯτࢦʢReactʣ ୯ҰํͷσʔλϑϩʔʢFluxʣ ܕγεςϜʢFlowtypeʣ
Λܦͨਓ͕ؒ ࣍ʹٻΊ͕ͪͳͷ
Πϛϡʔλϒϧ
Immutable.js • FacebookͷΠϛϡʔλϒϧͳΦϒδΣΫτ Λѻ͏ͨΊͷϥΠϒϥϦ • 2014͔Β͋Δ • ReactFlowtype΄Ͳʹͳͬͯͳ͍͠ ΘΕͯͳ͍ҹ
Why Immutable.js?
Why Immutable.js? • ෭࡞༻ͷগͳ͍ΦϒδΣΫτૢ࡞ • ΤϯςΟςΟૢ࡞ϩδοΫͷ • ϨϯμϦϯά੍ʹΑΔύϑΥʔϚϯενϡʔ χϯά
෭࡞༻ͷগͳ͍ΦϒδΣΫτૢ ࡞
෭࡞༻ͷগͳ͍ΦϒδΣΫτૢ ࡞
ΤϯςΟςΟૢ࡞ͷ
Immutable Model Class • ʹ
ΤϯςΟςΟૢ࡞ͷ
ෆཁͳϨϯμϦϯάͷ੍
ݒ೦
େن։ൃͳΒܕ͕΄͍͠
Immutable.js + Flowtype
it should ͍͍ײ͡ʹ ܕ͕͍ͭͨΠϛϡʔλϒϧͳ ΦϒδΣΫτΛѻ͑ͯ࠷ߴ
FlowtypeʹΑΔܕఆٛ
FlowtypeʹΑΔܕఆٛ
Immutable.Recordͷܕఆٛ
ͦΕҎલͷͱ͜ΖͰΤϥʔ
ܕఆٛϑΝΠϧΛௐΔ
ผ్ΫϥεఆٛΛ༻ҙ͢Δ
ͦͷ্ͰܧঝલʹΩϟετ
ظ௨ΓͷΤϥʔ
ͳΜͱ͔ ܕ͚Ͱ͖ͨ
͔ʹࢥ͕͑ͨ
None
Immutable.jsͷܕఆٛ • ίϝϯτΞτ෦ͷΑ͏ͳهड़ݱঢ়Ͱ͖ͳ͍
None
Immutable.js + Flowtype
it should ͍͍ײ͡ʹ ܕ͕͍ͭͨΠϛϡʔλϒϧͳ ΦϒδΣΫτΛѻ͑ͯ࠷ߴ
- ͍͍ײ͡ + ͭΒ͍ - ࠷ߴ + ยखམͪ 2 failure
ݟ • Immutable.Record + Flowtype ͭΒ͍ • ࡶͳهड़ͷʹܕ҆શͰͳ͍ • IssueݟΔͱօಉ༷ͷΛ๊͍͑ͯΔ
• ͍͔ͭ͘ͷղܾͷஹ͠ • ಉࣾ͡ͷOSSͳΒେৎͩΖ͏Έ͍ͨͳࡶͳߟ͑Α͘ ͳ͍
͋Γ͕ͱ͏͍͟͝·ͨ͠
versions •
[email protected]
• fl
[email protected]