import 'package:json_annotation/json_annotation.dart';


class UtcIso8601Converter implements JsonConverter<DateTime, String> {
  const UtcIso8601Converter();

  @override
  DateTime fromJson(String json) => DateTime.parse(json).toUtc();

  @override
  String toJson(DateTime value) => value.toUtc().toIso8601String();
}
