Returns a json representation of an instance of Stroke.
Map<String, dynamic> toJson() => { 'points': points.map((point) => point.toJson()).toList(), };