@page "/"
<h1>Example One</h1>
<p> Consumer passes no parameters. Default values for <strong>Header</strong> and <strong>ChildContent</strong> from derived component are used.</p>
<p style="font-style: italic">code</p>
<code>@ExampleOne</code>
<p style="font-style: italic">output</p>
<MyDerivedComponent/>
<hr/>
<h1>Example Two</h1>
<p> Consumer passes <strong>Header</strong> parameter, default <strong>ChildContent</strong> of derived component is used.</p>
<p style="font-style: italic">code</p>
<code>@ExampleTwo</code>
<p style="font-style: italic">output</p>
<MyDerivedComponent Header="Consumer Header"/>
<hr/>
<h1>Example Three</h1>
<p> Consumer passes both <strong>Header</strong> and <strong>ChildContent</strong> parameters.</p>
<p style="font-style: italic">code</p>
<code>
<pre>@ExampleThree</pre>
</code>
<p style="font-style: italic">output</p>
<MyDerivedComponent Header="Consumer Header">
<h4>Child Content - from consumer</h4>
</MyDerivedComponent>
@code {
private const string ExampleOne = @"<MyDerivedComponent/>";
private const string ExampleTwo = "<MyDerivedComponent Header=\"Consumer Header\"/>";
private const string ExampleThree = @"
<MyDerivedComponent Header=""Consumer Header"">
<h4>Child Content - from consumer</h4>
</MyDerivedComponent>";
}