apply method

String apply(
  1. int counter
)

Gets the appropriate text form based on the provided counter. If the counter is greater than 1, returns the plural form; otherwise, returns the singular form.

Implementation

String apply(int counter) => counter > 1 ? plural : singular;