choojs / choojs/nanohtml

The qualified name provided ('clipPath"') contains the invalid character '"'.

Open
#144 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
688
Forks
48
PR merge metrics
No merged PRs in 30d

Description

Trying to render [@stdlib/plot](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/plot/ctor) with `nanohtml`

```js
import Plot from '@stdlib/plot/ctor'
import html from 'nanohtml'
let plot = new Plot([[0,1,2]], [[0,2,1]])
document.body.appendChild(html(plot.render('html')))
```

getting
```sh
Uncaught (in promise) DOMException: Failed to execute 'setAttributeNS' on 'Element': The qualified name provided ('clipPath"') contains the invalid character '"'.
```

The HTML generated by `plot` is

```html

```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the supplied nanohtml reproduction using Plot.render('html') and inspect how SVG elements and namespaced attributes are created. Reproduce the setAttributeNS error in a browser, then verify that the same rendered plot can be appended without the invalid qualified name exception.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.