JSFiddle - React, Tailwind, and code Playground
HTML
<body></body>
JavaScript
Array.prototype.suffle = function () {
for (var i in this) {
var j = Math.floor(Math.random() * this.length);
this[i] = this[j] + (this[j] = this[i], 0);
}
return this;
};
var x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
$('body').append(JSON.stringify(x) + "<br>");
$('body').append(JSON.stringify(x.suffle()));