title: How to determine if a RenderFragement has a content
body: <p>I've just built a very simple razor component for templating a page header. Now I've noticed that my condition regarding the ChildComponent != null is always true. Is there a way to check if the ChildContent has any real content defined?</p>
  <p>In my example the PageTitleSecondaryRow will always be rendered into my page, even if ChildContent is empty (but it is not NULL). Which Options do I have. As a workaround I will now make an custom RenderFragment property which is null by initialization. But I do not think that this is the final solution.</p>
  <pre><code>&lt;div class=&quot;wrapper border-bottom white-bg page-heading&quot;&gt;
      &lt;div class=&quot;row&quot; id=&quot;PageTitlePrimaryRow&quot;&gt;
  
          &lt;div id=&quot;PageTitleIconColumn&quot;&gt;
              @(IconMarkup())
          &lt;/div&gt;
          &lt;div  id=&quot;PageTitleTextColumn&quot;&gt;
              &lt;h2&gt;
                  @Title
              &lt;/h2&gt;
              @if (Elements != null &amp;&amp; Elements.Count &gt; 0)
              {
                  &lt;TitleBreadcrumbs Elements=&quot;@Elements&quot; /&gt;
              }
          &lt;/div&gt;
          &lt;div  id=&quot;PageTitlePostColumn&quot;&gt;
          &lt;/div&gt;
      &lt;/div&gt;
      @if (ChildContent != null )
      {
          &lt;hr /&gt;
          &lt;div id=&quot;PageTitleSecondaryRow&quot;&gt;
              @ChildContent
          &lt;/div&gt;
      }
  &lt;/div&gt;
  </code></pre>