Skip to content

Instantly share code, notes, and snippets.

Forked from jefffriesen/
Last active Feb 1, 2017
What would you like to do?
Chrome SVG Performance Regression

An example of the Chrome performance regression handling complex SVGs

Steps to recreate

<!DOCTYPE html>
<meta charset="utf-8">
.zip {
fill: white;
stroke: #CCC;
stroke-width: .5px;
cursor: pointer;
.zip:hover {
fill: red;
<script src=""></script>
<script src=""></script>
<script src=""></script>
var width = 960,
height = 500;
var path = d3.geo.path();
var svg ="body").append("svg")
.attr("width", width)
.attr("height", height);
.defer(d3.json, "zips_us_topo.json")
function ready(error, us) {
.attr("class", "counties")
.data(topojson.feature(us, us.objects.zip_codes_for_the_usa).features)
.attr("class", "zip")
.attr("data-zip", function(d) {return; })
.attr("data-state", function(d) {return; })
.attr("data-name", function(d) {return; })
.attr("d", path);
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment