happy-dom icon indicating copy to clipboard operation
happy-dom copied to clipboard

Can't parse element attribute without quotes

Open SettingDust opened this issue 1 year ago • 0 comments

Describe the bug <script type=application/ld+json> transform to <script type="application/ld" json="">

https://html.spec.whatwg.org/multipage/syntax.html#attributes-2

To Reproduce Parse below string

`
      <html><head>
        <script type='application/ld+json'>{
          "@context": "https://schema.org",
          "@type": "NewsArticle",
          "headline": "headline",
          "@graph": [{
            "headline": "Nested headline"
          }]
        }</script></head></html>`

Expected behavior Parsable the standard

Screenshots 图片

Device:

  • OS: [e.g. iOS] Windows
  • Browser [e.g. chrome, safari] Node.Js 20
  • Version [e.g. 22] 13.3.1

SettingDust avatar Jan 25 '24 16:01 SettingDust