For linear “first in first out” cases, where the first thing added has to be done before the next.

The checkboxes and "X" for highlghting just demos how to use the HTML5 data- attribute when generating elements.

Source code

Adapted from Queue Data Structure in JavaScript