1. cliveportman
  2. /code
  3. /add-leading-zeros-to-single-digit-numbers-using-twig

Add leading zeros to single digit numbers using Twig

Useful when you need to convert single digit days or months to having a leading zero using Twig:

00

Hat-tip.