You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to use d3 behaviors installed on individual view elements without resorting to weird calls in the templates.
However, when creating a g as the root element of a component, its namespaceUri is assumed to be xhtml, because it doesn't inherit anything from the parseNode.parent (undefined), and there appears to be no way to inject it: because of this, it will not be drawn... we had to use the svg-crowbar to even determine the namespace!
Background
I am using derby-standalone to prototype an app.
I want to use d3 behaviors installed on individual view elements without resorting to weird calls in the templates.
However, when creating a
g
as the root element of a component, itsnamespaceUri
is assumed to bexhtml
, because it doesn't inherit anything from theparseNode.parent
(undefined
), and there appears to be no way to inject it: because of this, it will not be drawn... we had to use the svg-crowbar to even determine the namespace!Example
Possible Solution
One possible solution would be to allow template writers to add an
xmlns
attribute to theg
:This would let a single template be written, for example, for both svg and html embedding:
The text was updated successfully, but these errors were encountered: