-
-
Save anonymous/3d99d9e9628049235601a17b40167e1b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
d3.json('/mapbox-gl-js/assets/significant-earthquakes-2015.geojson', function(err, data) { | |
if (err) throw err; | |
// Create a month property value based on time | |
// used to filter against. | |
data.features = data.features.map(function(d) { | |
d.properties.month = new Date(d.properties.time).getMonth(); | |
return d; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment