JSFiddle - React, Tailwind, and code Playground

JavaScript

var list = [];

for (var i=1; i<=12; i++) {
     list.push(i);   
}

for (var i=0; i<12; i++) {
    var index = Math.floor(Math.random() * 12);
    var tmp = list[i];
    list[i] = list[index];
    list[index] = tmp;
}

console.log(list);