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
8k
How to control loading state in React
tohashi
2
190
フロントエンドのモダン化とJavaScriptモジュールの 依存解決
tohashi
8
3k
Featured
See All Featured
Scaling GitHub
holman
459
140k
Site-Speed That Sticks
csswizardry
3
310
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.4k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.3k
Code Reviewing Like a Champion
maltzj
521
39k
Docker and Python
trallard
43
3.2k
Six Lessons from altMBA
skipperchong
27
3.6k
No one is an island. Learnings from fostering a developers community.
thoeni
20
3.1k
Building Applications with DynamoDB
mza
93
6.2k
Testing 201, or: Great Expectations
jmmastey
41
7.2k
Gamification - CAS2011
davidbonilla
80
5.1k
Building an army of robots
kneath
302
45k
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]