joinAnd method

String joinAnd({
  1. Locale? locale,
})

Join a list in a locale-dependent manner using and-based grouping.

Example: "A, B, and C". See also ListType.and.

import 'package:intl4x/list_format.dart';

void main() {
  print(['A', 'B', 'C'].joinAnd()); // Prints 'A, B, and C'
}

For more options, use ListFormat directly.

Implementation

String joinAnd({Locale? locale}) =>
    ListFormat(locale: locale, type: ListType.and).format(this);