dateTimeToIso8601String function
Converts a DateTime object to an ISO 8601 string.
Returns null if the provided dateTime is null.
@ai Use this function to serialize DateTime objects for storage or transmission.
Implementation
String? dateTimeToIso8601String(final DateTime? value) =>
value?.toIso8601String();