Skip to content

> inside scripts get escaped. #199

@hacknlove

Description

@hacknlove
> const { DOMParser } = require("linkedom");
undefined
> const parser = new DOMParser();
undefined
> parser.parseFromString(`<html><body><script>(() => {if (5>4) { console.log('hello') }})()</script></body></html>`).toString()
`<?xml version="1.0" encoding="utf-8"?><html><body><script>(() =&gt; {if (5&gt;4) { console.log('hello') }})()</script></body></html>`

It should be () => { and 5>4

I'm using linkedom@0.14.25

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions