This simple bar chart demonstrates two new features of D3 2.6:
Namespaces are now optional! You can now append an SVG element by just saying append("svg")
, without specifying the namespace explicitly as “svg:svg”. Adding an element whose name is a known prefix (in d3.ns.prefix) implies a namespace; similarly, appending or inserting an element will inherit the namespace from its parent.
The axis component now supports ordinal scales. The labels on the left side of the bar chart are rendered with the axis component.