Re:Why I'm not a React Native developer
by debaserab2 on Saturday August 19, 2017 @03:40PM
(#15055166)
this.setState({ isConnected: !!weAreConnected })
[ Parent
| on HN ]
Re:Why I'm not a React Native developer
by hypervis0r on Saturday August 19, 2017 @03:46PM
(#15055207)
This^, plus, you shouldn't really have "null" or "undefined" variables which you treat as bool (if you do, then that's a bug)
Re:Why I'm not a React Native developer
by DeonPenny on Saturday August 19, 2017 @07:37PM
(#15056218)
Ding ding ding right answer. This is the way most senior javascript devs would right it.
Re:Why I'm not a React Native developer
by corn13read on Sunday August 20, 2017 @03:40AM
(#15057381)
They'd right it if they were fixing it or write it if they were writing it ;)