title: React functional component - is it possible to pass props to { children }?
body: <p>Workaround at the bottom of the question.</p>
  <p>I am trying to pass props down to a child component using {children}.</p>
  <p>The Father component:</p>
  <pre><code>const FatherComp = ({ children, propsToPassToChild }) =&gt; (
      &lt;div&gt;Dynamic component content: 
          {children}
      &lt;/div&gt;
  )
  </code></pre>
  <p>The child component:</p>
  <pre><code>const ChildComp = ({ childProps }) =&gt; &lt;p&gt;This is the dynamic content&lt;/p&gt;
  </code></pre>
  <p>Using them like so:</p>
  <pre><code>&lt;FatherComp&gt;
      &lt;ChildComp/&gt; // childProps cannot be passed here since it's inside FatherComp
  &lt;/FatherComp&gt;
  </code></pre>
  <p>I want to pass to the ChildComp the props (propsToPassToChild ) from the FatherComp directly:</p>
  <pre><code>const FatherComp = ({ children, propsToPassToChild }) =&gt; (
      &lt;div&gt;Dynamic component content: 
          &gt;&gt;&gt;&gt;&gt; {children} &lt;&lt;&lt;&lt;&lt; *passing the props somewhere here* 
      &lt;/div&gt;
  )
  </code></pre>
  <p>Is it possible to achive what I am trying to do with react functional components directly and without state management?</p>
  <p>Thanks!</p>
  <p>************ My solution ***********</p>
  <p>So after a little while in a different project I came accross the same question and I found out a solution.</p>
  <pre><code>const Father = ({ child }) =&gt; {
      return (
          &lt;div&gt;
              {child({ text: 'I am props from father' })}
          &lt;/div&gt;
      );
  };
  
  const Child = ({ text }) =&gt; {
      return (
          &lt;div&gt;Hey there {text}&lt;/div&gt;
      );
  };
  </code></pre>
  <p>and render the Father component:</p>
  <pre><code>const App = () =&gt; &lt;Father child={Child} /&gt;
  </code></pre>
  <p>Just pass the child in the props of the father as a function that returns a component.
  Altough it's not a 'direct' solution this solved the problem without wrapping the child with the father.</p>