React people call this kind of thing "higher order components"
-
-
Replying to @wycats
Ilya Radchenko Retweeted Kent C. Dodds
Just watched this video and it seems this technic is actually called render propshttps://twitter.com/kentcdodds/status/911086452699627522 …
Ilya Radchenko added,
1 reply 0 retweets 1 like -
-
Replying to @kentcdodds @wycats
Well I guess your right in regards to tagName: '' but I'm talking more about the use of that to build declarative apis with {{yield}}
1 reply 0 retweets 1 like -
Replying to @knownasilya @kentcdodds
I've completely lost this thread at this point...
2 replies 0 retweets 1 like -
Watched! "Render prop" is synonymous with "Block Param" in Ember: <Mouse>{mouse => ...}</Mouse> {{
#my-mouse as |mouse|}}...{{/my-mouse}}1 reply 0 retweets 3 likes -
And with the upcoming angle bracket syntax in Ember: <Mouse as |mouse|>...</Mouse>
1 reply 0 retweets 2 likes -
fwiw I really do think that having a built-in syntax for this helps cut through a lot of the debate about whether this is a good idea.
1 reply 1 retweet 3 likes -
And nothing is stopping JSX from having syntax like <Mouse as |foo|> or something that people think looks more like JS like <Mouse (foo)>
2 replies 0 retweets 0 likes -
Replying to @wycats @kentcdodds
Yeah, when I watched that video it was unclear that 'mouse' was coming from that component.
1 reply 0 retweets 1 like
He says it couldn't be clearer. There's at least one way!
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.