I have a force layout that I have created using d3.js
I would like to have both the normal functionality of a draggable force layout as well as the ability to zoom.
I have basically copy/pasted the zooming code from (http://jsfiddle.net/nrabinowitz/QMKm3/). This is the same way of zooming that Mike Bostock uses in (http://bl.ocks.org/mbostock/3680957).
Here is my code: http://jsfiddle.net/kM4Hs/6/
The zooming works fine, but I am unable to select single nodes in the force layout and drag them around.
I have found the culprit to be the fact that both authors use d3.v2.js rather than the newer d3.v3.js. When I change my import to v2 it works perfectly. However, I would like to use v3 if possible.
<script type='text/javascript' src='http://d3js.org/d3.v3.min.js'></script>
versus
<script type='text/javascript' src='http://d3js.org/d3.v2.min.js'></script>
why does v3 break the force layout when v2 doesn't, and more importantly, what can I do to fix it?
Thanks in advance!