@dan_abramov except there is an else block, it’s just implicitly `undefined`
-
-
Replying to @ForbesLindesay
@forbeslindesay The idea is to have JSX expression containers have the same semantics as do expressions.@dan_abramov1 reply 0 retweets 0 likes -
Replying to @sebmck
@sebmck@dan_abramov but what’s the justification for do expressions. I haven’t seen any discussion on esdiscuss1 reply 0 retweets 0 likes -
Replying to @ForbesLindesay
@forbeslindesay Pretty sure it's from the ES4 era. Nicer than an IIFE.@dan_abramov1 reply 0 retweets 1 like -
Replying to @sebmck
@forbeslindesay Also ref http://wiki.ecmascript.org/doku.php?id=strawman:do_expressions …@dan_abramov1 reply 0 retweets 0 likes -
Replying to @sebmck
@sebmck@dan_abramov the implicit return inside if/else etc. is very strange.1 reply 0 retweets 0 likes -
Replying to @ForbesLindesay
@forbeslindesay It's reusing existing completion record semantics. Same behaviour as eval etc. Most commonly used in REPLs.@dan_abramov1 reply 0 retweets 0 likes -
Replying to @sebmck
@sebmck@dan_abramov I think it will surprise people that `while (foo) <Element/>` doesn’t produce a list of elements1 reply 0 retweets 0 likes -
Replying to @ForbesLindesay
@forbeslindesay Hm, why would it?@dan_abramov1 reply 0 retweets 0 likes -
Replying to @sebmck
@sebmck@dan_abramov because that’s probably the developers intention. And nobody has learnt the rules for completion records1 reply 0 retweets 0 likes
@forbeslindesay Would a dev really assume it'd return a list of elements? What about it implies that? @dan_abramov
-
-
Replying to @sebmck
@sebmck@dan_abramov as a designer, I see {if (foo) <Element/>} and assume <Element/> is a statement that adds an elem to the current parent0 replies 0 retweets 0 likesThanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
he/him 