Closed mbostock closed 3 years ago
This is a hard issue. Tracking namespace is ugly. In our Julia fork, we decided to convert snake_case
to kebab-case
but, due to SVG, leave camelCase
alone. This is working well. HTML, SVG and MathML do not use snake_case
. That said, doing this would be an incompatible break for an established project such as this. However, perhaps you could add snake_case
now; and set a flag to disable camelCase
.
HTML5 defines automatic case correction for certain SVG attributes:
However, in order to do this, we’d need to track whether we’re in the SVG namespace, because it should only apply to SVG elements.