fangwei716 / 30-days-of-react-native

30 days of React Native demos
6.82k stars 1.46k forks source link

One bug about setState in Day1 #17

Closed arthurzoubin closed 8 years ago

arthurzoubin commented 8 years ago

On line 50 of day1.js, when we use the watchOn, find the it can not be change on line 47. Because function setState is a asynchronous function. Can look at https://facebook.github.io/react/docs/component-api.html

fangwei716 commented 8 years ago

Thank you very much for pointing out. I have fixed it.