Hooks are a new feature proposal that
lets you use state and other React
features without writing a class. They’re
currently in React v16.7.0-alpha and
being discussed in an open RFC.
IUUQTSFBDUKTPSHEPDTIPPLTSFGFSFODFIUNMΑΓҾ༻
!5
Slide 6
Slide 6 text
ҙ༁
w )PPLT3FBDUͷ࣍ͷόʔδϣϯ
Ͱ͑Δ༧ఆͷͭ
w DMBTTͳ͠ͰTUBUFͱ͔͕͑Δ
w ·ͩ3'$ͳײ͡Ͱ༷ࡦఆத
!6
Slide 7
Slide 7 text
/P#SFBLJOH$IBOHFT
w ͏ͷҙͩ͠ޙํޓੑͱ͔
Ϳͬյ͞ͳ͍Α
w ผʹDMBTTΛͳ͘͢ؾͳ͍Α
w 3FBDUͷߟ͑ํίϯηϓτͱ͔
มΘΒͳ͍Α
!7
Slide 8
Slide 8 text
)PPLT"1*ͷհ
!8
Slide 9
Slide 9 text
ࠓհ͢Δͷ
w VTF4UBUF
w VTF&GGFDU
w VTF3FEVDFS
!9
Slide 10
Slide 10 text
ࠓհ͠ͳ͍ͷ
w VTF$POUFYU
w ଞɺ"EEJUJPOBM)PPLTͷେ
w VTF$BMMCBDL
VTF.FNP
VTF3FG
FUD
!10
Slide 11
Slide 11 text
VTF4UBUF
w TUBUF͕͑Δ
w ݱࡏͷঢ়ଶͱঢ়ଶΛม͑ΔؔΛฦ
͢
w چདྷͷTFU4UBUFͷΑ͏ʹΦϒδΣ
ΫτͷϚʔδ͠ͳ͍ͷͰҙ
!11
Slide 12
Slide 12 text
VTF&GGFDU
w ඳը͕ऴΘ͔ͬͯΒ࣮ߦ͞ΕΔ
w %JE.PVOU%JE6QEBUFʹ͍ۙ
w ୈೋҾͰࢹ͢ΔରΛࢦఆ͢Δ
w ୈҰҾͷฦΓͷؔͰΫϦʔϯ
Ξοϓ͢Δ
!12
Slide 13
Slide 13 text
VTF3FEVDFS
w 'MVYϥΠΫͳ͜ͱ͕Ͱ͖Δ
!13
Slide 14
Slide 14 text
ॴײ
w SFDPNQPTFSFEVYͳͲΛͬ
ͯͬͯͨ͜ͱͷҰ෦3FBDU͚ͩ
ͰͰ͖ͦ͏
w ͠Β͘ϕετϓϥΫςΟεΛ
ࡧ͢Δ͜ͱʹͳΓͦ͏
!14