I have Parent and Child TagHelper.. I have set attribute "parentTag" for Child Tag and yet it displays outside that parent Tag. How to restrict it from appearing outside parent Tag
[HtmlTargetElement("TestParent")]
public class Parent: TagHelper{
}
[HtmlTargetElement("TestChild",ParentTag = "TestParent")]
public class Child : TagHelper
{
}
What it need is that "TestChild" should not appear outside "TestParent"
For example:
<TestChild value=2></TestChild>
Above code must throw error or should not be shown in intellisense as it not enclosed by parent Tag "Testparent"