elem-go icon indicating copy to clipboard operation
elem-go copied to clipboard

Add support for missing HTML5 elements (meta-issue)

Open whisk opened this issue 6 months ago • 0 comments

Motivation

I was wondering if elem-go supports all elements defined by the HTML5 standard, and it appears that a few are missing. I wrote a simple tool to extract elements from the standard specs so this should be precise (unless I missed some edge case when parsing the specs).

All missing elements are quite niche and I personally have never needed them in the library. Hovewer for the sake of completeness it would be nice to have them all. Also this work can be a good way to start contributing to the project.

Description

Add support for the following HTML5 elements:

  • [ ] bdi
  • [ ] bdo
  • [ ] canvas
  • [ ] caption
  • [ ] col
  • [ ] colgroup
  • [ ] del
  • [ ] dfn
  • [ ] embed
  • [ ] ins
  • [ ] marquee
  • [ ] object
  • [ ] picture (#154 )
  • [ ] s
  • [ ] search
  • [ ] slot
  • [ ] template
  • [ ] track (#155 )
  • [ ] wbr (#156 )

What to do

  1. Pick a missing element and add a corresponding method to elements.go.
  2. Check if the element has unique attributes never added before to attrs package.
  3. Note that some elements do not have the ending tag, like wbr or track.
  4. Please remember the tests!

whisk avatar Jun 29 '25 14:06 whisk