zeroPad function

String zeroPad(
  1. num number
)

Pads a number with a single zero, if it is less than 10

Implementation

String zeroPad(num number) => (number < 10 ? '0' : '') + number.toString();