JavaScript helper functions for manipulating GeoJSON