Note: Chrome has strict permissions for reading files out of the local file system. Some examples use AJAX which works differently via HTTP instead of local files. For the best experience, load the D3 examples from your own machine via HTTP. Any static file web server will work; for example you can run Python's built-in server:
python -m SimpleHTTPServer 8888
Once this is running, go to: http://localhost:8888/examples/
This repository should work out of the box if you just want to create new visualizations using D3. On the other hand, if you want to extend D3 with new features, fix bugs, or run tests, you'll need to install a few more things.
brew install node brew install npm
Next, from the root directory of this repository, install D3's dependencies:
You can see the list of dependencies in package.json. NPM will install the packages in the node_modules directory.
To run the tests, use: