Skip to content

types are missing for <svg> tags usage in JSX #277

Description

@thescientist13

What happened?

Observed https://github.com/AnalogStudiosRI/www.analogstudios.net/pull/112/changes#diff-b2b74aad560dc69e0dca07a6eec76d2f48dbcf3d0010bf19fbe1f491b600d941R104 that <svg> tags are throwing TSX errors
Image

Steps to reproduce

Author some TSX with an <svg> tag

<button type="button" class="btn" onclick={this.toggleShowSocialShare}>
  <svg
    class="svg-inline--fa fa-share-alt fa-w-14"
    aria-hidden="true"
    data-prefix="fas"
    data-icon="share-alt"
    role="img"
    xmlns="http://www.w3.org/2000/svg"
    viewBox="0 0 448 512"
    data-fa-i2svg=""
  >
    <path
      fill="currentColor"
      d="M352 320c-22.608 0-43.387 7.819-59.79 20.895l-102.486-64.054a96.551 96.551 0 0 0 0-41.683l102.486-64.054C308.613 184.181 329.392 192 352 192c53.019 0 96-42.981 96-96S405.019 0 352 0s-96 42.981-96 96c0 7.158.79 14.13 2.276 20.841L155.79 180.895C139.387 167.819 118.608 160 96 160c-53.019 0-96 42.981-96 96s42.981 96 96 96c22.608 0 43.387-7.819 59.79-20.895l102.486 64.054A96.301 96.301 0 0 0 256 416c0 53.019 42.981 96 96 96s96-42.981 96-96-42.981-96-96-96z"
    ></path>
  </svg>
  SHARE THIS PAGE
</button>

Environment

Latest WCC

Additional Context

As a small bonus to include as part of this if possible, is to add support for tabindex on <button> tags
Image

Metadata

Metadata

Labels

Type

Fields

No fields configured for Bug.

Projects

Status
✅ Done

Relationships

None yet

Development

No branches or pull requests

Issue actions