Counter in Vanilla JavaScript

screenshot