0

I have read the post about to insert a label into a d3 chart but I don't see the text

This is the post: How to add to text to the Zoomable Icicle d3 graph?

This is my page with code: http://mirkotinelli.altervista.org/icicle/altro.html

Community
  • 1
  • 1
  • Welcome to Stack Overflow! Please read [how to ask a good question](http://stackoverflow.com/help/how-to-ask) and also [what have you tried](http://mattgemmell.com/what-have-you-tried/). – Jason Aller May 31 '14 at 05:32
  • ...and if you find an answer acceptable, remember to click the checkmark – sfletche May 31 '14 at 05:34

1 Answers1

2

In the following line from your source

.text(function(d) { return d.key })

you reference d.key which doesn't exist in your json.

Replace d.key with d.name

.text(function(d) { return d.name })
sfletche
  • 47,248
  • 30
  • 103
  • 119