Open bayanr opened 10 years ago
Im not sure I fully understand. HTML6 has the idea of a small set of tags implemented by the browser. Are you talking about just div
and li
s? I'm not sure I see a point to div
since every new tag would act just like a div already.
I guess my focus here is more on the browser implementation than anything else. Simpler implementation means less surprises when putting things together and your html6 accounts for that apparently, forgive me for misunderstanding.
@bayanr yeah, so the elements listed in the docs are the small set of ones implemented by the browser itself. For example: https://github.com/OscarGodson/HTML6#htmlbutton
That one the browser creates a button and handles all the stuff that goes with it (like pressing enter on it fires events, you can tab to it, etc)
I don't understand, would actions specific to the button be handled by the browser internals, or would the event handler trigger events specified in the syntax facing the user?
It would look and act exactly like a button element now
That is the problem. While html is largely well defined there are a bunch of corner cases which are unaccounted for, a simple one being inline divs. Instead of defining each and every tag we can define a small set of generic tags and formally define the rest of html tags in terms of those.
How is an "inline div" unaccounted for exactly? It seems like your describing HTML as it us now from my understanding.
@bayanr Isn't this an easier way?
li{
display: block;
}
ul, ol{
display: list-item;
}
ul{
list-style-type: disc;
list-style-position: inside;
}
ol{
list-style-type: decimal;
list-style-position: inside;
}
CSS. No need for special tags.
HTML6 is beautiful because nothing is defined and you can define it yourself. If you're good, then your tags will be clearly defined and predictable.
Ah, now I see. Shadow DOM is what you're searching for. And, yes, it's cool! See this article on HTML5Rocks.
What could be great is if the HTML spec was based on a small set of tags which had clearly defined and predictable behaviour.
You could you could have the
<html:div>
tags implemented by the browser and the higher level tags implemented by those low level ones. For example<html:li> </html:li>
could be implemented using my probably awful syntax language(pasl)with [content] being replaced with the content of the tag.
I'm not sure how feasible this is, but it sure would be nice and would make for a far simpler browser implementation, more uniformity across browsers as well as a more flexible language in general.
Thoughts?