Answers for "add html to angular component through component"

1

write html inside component angular

<div class="myClass">
    <div class="myHeader" id="headerId"> Title </div>
    <div class="myContent" id="contentId"> <ng-content></ng-content> </div>
</div>

<my-component title="Title" headerID=headerId contentID=contentID>
    <<Some HTML code>>
</my-component>
Posted by: Guest on June-25-2021

Browse Popular Code Answers by Language