[x3d-public] custom elements in HTML5

John Carlson yottzumm at gmail.com
Wed Aug 14 16:01:04 PDT 2019


I think JSON is moving to namespaces/multischema.   It would be good to
look at draft08+

John

On Wed, Aug 14, 2019 at 5:44 PM Brutzman, Donald (Don) (CIV) <
brutzman at nps.edu> wrote:

> Thanks for this excellent analysis Andreas.
>
> On 8/1/2019 12:59 PM, Andreas Plesch wrote:
> > As I had mentioned  at Web3D 2019, the use of dashes is a name space
> mechanism in HTML5,. Let me follow up with background and references:
> >
> > A) What is HTML5 ?
> >
> > I believe the W3C and WHATWG spec. divergence was resolved:
> >
> > WHATWG:
> > https://html.spec.whatwg.org/multipage/introduction.html#is-this-html5?
> >
> > W3C:
> > latest recommendation:
> > https://www.w3.org/TR/2017/REC-html52-20171214/
> > latest working draft:
> > https://www.w3.org/TR/2018/WD-html53-20181018/
>
> Indeed there is a long and colorful history of interactions between WHATWG
> and W3C.  Of interest:
>
>         W3C
>         https://www.w3.org
>         https://en.wikipedia.org/wiki/WHATWG
>
>         WHATWG
>         https://whatwg.org
>         https://en.wikipedia.org/wiki/World_Wide_Web_Consortium
>
>         W3C and the WHATWG signed an agreement to collaborate on a single
> version of HTML and DOM
>         https://www.w3.org/blog/news/archives/7753
>
>         W3C and WHATWG to work together to advance the open Web
>         28 May 2019 by Jeff Jaffe, W3C CEO
>
> https://www.w3.org/blog/2019/05/w3c-and-whatwg-to-work-together-to-advance-the-open-web-platform
>
>         Memorandum of Understanding Between W3C and WHATWG
>         https://www.w3.org/2019/04/WHATWG-W3C-MOU.html
>
> Web3D Consortium is a liaison member of W3C.
>
>         https://www.w3.org/Consortium/Member/Testimonial/#t393
>         "The Web3D Consortium, like W3C, supports open standardization.
> Web3D's open standards for real-time 3D communication include X3D, a
> powerful and extensible XML-based ISO standard for 3D visual effects,
> behavioral modeling, interaction and interoperability. Web3D membership
> includes companies, institutions, working groups and individuals.
> W3C Member since 1 April 1999."
>
> Of note is that Web3D can only align X3Dv4 with approved international
> standards.  I think this means the standards you indicated (HTML5.2 and
> potentially 5.3) as we proceed with X3Dv4.
>
>         X3D Version 4 Strategy
>         https://www.web3d.org/X3D4
>
> > B) Why custom elements ?
> >
> > Custom elements are the recommended, standardized method to extend HTML5
> to other domains. However, both x3dom and x-cite use other mechanisms.
> Currently, x3dom uses Unknown Elements and x-cite uses DOM provided XML
> parsing.
> >
> > Unless W3C/WHATWG adopts X3D as native elements (such as SVG) which is
> unlikely in the near to medium term, the custom element specification would
> be the best fit to strongly couple X3D to HTML.
>
> Agreed here.  Good topic for discussion on a future X3D teleconference
> when convenient to you.
>
> Recommended course of action:
> - Work with HTML5 custom elements.
> - Look at how SVG is supported.
> - Once stable and specified, consider proposal for X3D as native elements
> to W3C.
>
> > C) Dashes in custom element names
> >
> > A valid custom element must contain a dash ("-") character. See the
> production here:
> >
> > WHATWG:
> >
> https://html.spec.whatwg.org/multipage/custom-elements.html#valid-custom-element-name
> >
> > W3C:
> >
> https://www.w3.org/TR/2018/WD-html53-20181018/semantics-scripting.html#valid-custom-element-name
> > https://www.w3.org/TR/2017/REC-html52-20171214/dom.html#elements links
> to
> > https://www.w3.org/TR/custom-elements/#valid-custom-element-name
> > which points back to HTML5.3 draft
> >
> > The suggestion would be to add a "x3d-" prefix to all X3D nodes and
> keywords. "x-" is already used by multiple custom element collections.
>
> Sounds like a do-able plan.
>
> Interestingly this is almost identically similar to practice in python,
> which also has pythonic form of "prefix.element" for common use to avoid
> class collisions - for example x3d.X3D, x3d.head, x3d.Scene, x3d.Group, etc.
>
>         X3D Resources, Examples: Scene Archives for X3D
>
> https://www.web3d.org/x3d/content/examples/X3dResources.html#Examples
>
>         HelloWorld.py
>         https://www.web3d.org/x3d/content/examples/HelloWorld.py
>
> The time is approaching when we should compare these:
> - X3DOM form,
> - X_ITE form,
> - Custom HTML5 including "custom"-prefixed X3D elements, and
> - any other alternatives.
>
> Added as Mantis issue 1260.
>
>         Use of custom elements (x3d- prefix) for X3Dv4 in HTML5
>         https://www.web3d.org/member-only/mantis/view.php?id=1260
>
> all the best, Don
> --
> Don Brutzman  Naval Postgraduate School, Code USW/Br
> brutzman at nps.edu
> Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149
> X3D graphics, virtual worlds, navy robotics
> http://faculty.nps.edu/brutzman
> _______________________________________________
> x3d-public mailing list
> x3d-public at web3d.org
> http://web3d.org/mailman/listinfo/x3d-public_web3d.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20190814/671a1eee/attachment-0001.html>


More information about the x3d-public mailing list