Converts the Coordinate to a JSON coordinate List.
Example:
Coordinate(1, 2).toJson(); // [1, 2]
List<double> toJson() { return [longitude, latitude]; }