[Ur] HTML5 support (was: Re: PATCH: <progress> tag)
austin seipp
as at hacks.yi.org
Sat Sep 24 17:01:22 EDT 2011
Heh, if it's considered a feature and not a bug, I guess I can't
technically do much in the way of arguing. On principle, I would even
agree! :) I just don't like maintaining my own branches if it all
possible, and like to feed my work back. The <progress> tag was mostly
for my own amusement and I was going to write something about Ur/Web
and thought that + an FRP example would work well. But I digress...
I was going to strike a compromise and ask if it would be allowable to
reject any HTML5 elements by default unless a '-html5' flag was passed
or something, since that seems much more sound, but beyond elements
there are a few new attribute definitions as well as deprecations etc.
The current html5-diff sez:
http://www.w3.org/TR/html5-diff/#language
I'm not sure what the proper way to structure such functionality is,
in the face of new/old/deprecated attributes across tags that already
exist. Some basis.urs tags will need to have an extra attribute for
html5, or according to the standard should not have one anymore, but
now the compiler has to know more about each tag and which attributes
are html5/4, and when attribute use is valid and when it's not. Yuck.
But maybe there's something that could keep it simple.
Of course, based on discussions on the list earlier this month,
perhaps sticking rigidly to the standard isn't so important,
especially if parts of html5 are still in flux. I'm reluctant to add a
new flag and just the elements though (even though it's mostly what I
want, I was also thinking about <video>) as this is the easy part, and
a lot of the elements probably won't change radically in structure -
surely if you give people that, they will want the new attributes soon
after (on existing tags,) and that seems quite a bit more difficult to
ensure the default stays HTML4.
If you think there is a 'right way' to do this, or if anyone else
reading wants to chime in with any projected use cases/ideas, I'm more
than willing to put in the work and do it correctly. But if there
isn't a need, or supporting it would just be far too much work for
little gain at the moment, then I suppose I'll just have to keep my
branches afloat by myself with whatever works for me, until another
day. :)
On Sat, Sep 24, 2011 at 9:19 AM, Adam Chlipala <adamc at impredicative.com> wrote:
> austin seipp wrote:
>>
>> I added a<progress> tag to the standard library.
>>
>
> Am I right that this tag is new in HTML5, and that all previously supported
> tags were pre-HTML5? It's not clear to me that it isn't a useful function
> of the compiler to detect HTML5 uses as browser incompatibility bugs. ;)
>
> _______________________________________________
> Ur mailing list
> Ur at impredicative.com
> http://www.impredicative.com/cgi-bin/mailman/listinfo/ur
>
--
Regards,
Austin
More information about the Ur
mailing list