Just working on HTML, it has happened that I have to use lots of times a structure like the following one:
<div class="class1"><p class="class2">Title</p><div class="class3">
Content
</div></div>
and the structure is repeated and also nested. So it would be very helpful for me to be able to define something of the type
<newtag tit="Title">Content</newtag>
That is: instead of having the code
<div class="class1"><p class="class2">External box</p><div class="class3">
<div class="class1"><p class="class2">Medium box</p><div class="class3">
<div class="class1"><p class="class2">Inner box</p><div class="class3">
<p>Something</p>
</div></div>
</div></div>
<div class="class1"><p class="class2">Another medium box</p><div class="class3">
<p>Something else</p>
</div></div>
</div></div>
I would have
<!--some previous code (perhaps in html, css or js)-->
<newtag tit="External box">
<newtag tit="Medium box">
<newtag tit="Inner box">
<p>Something</p>
</newtag>
</newtag>
<newtag tit="Another medium box">
<p>Something else</p>
</newtag>
</newtag>
I imagine there must be something like this, but I really do not know how to do it. Is there some way to implement the previous structure? That is, what should be the 'some previous code'?
Any suggestion is welcome.