Re: [whatwg/dom] Implementing Document.prototype.createHTML (#996)

> It doesn't make a difference if there were a thousand

Imagine JS had thousand ways to *eval* code ... and the count is already pretty high ... would you propose a new way to *eval* ?

@manngo your code could be simpler:

```js
let template=document.createElement('template');
template.innerHTML = '<img width="40" height="30" alt="alt text" title="title text">';
let img=template.content.lastChild;
```

My point is: as the boilerplate is minimal, but a new method that encourage even more `innerHTML` in the wild is proposed, are we sure we really want this new method at all?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/996#issuecomment-868982735

Received on Saturday, 26 June 2021 10:41:14 UTC