If you use react router, is some situations you need to pass a function as children.
It would be nice to be able to use the same syntax as them.
<Route path={to} children={({ match }) => (
<li className={match ? 'active' : ''}>
<Link to={to} {...rest}/>
</li>
)} />
is easier to reason about than
<Route path={to}>
{({ match }) => (
<li className={match ? 'active' : ''}>
<Link to={to} {...rest}/>
</li>
)}
</Route>
There could be a config to allow functions (not the default).