JSFiddle - React, Tailwind, and code Playground

HTML

<div class="images">
<div class="image">йа картинко 1</div>
<div class="image">йа картинко 2</div>
<div class="image">йа картинко 3</div>
</div>
<button id="shuffle">Перемешать</button>

JavaScript

function shuffle(a){for(var e=a.length;e&&--e;){var t=a[e],n=Math.floor(Math.random()*(e+1));a[e]=a[n],a[n]=t}return a}

document.getElementById('shuffle').addEventListener('click', () => {
    let imagesContainer = document.querySelector('.images'),
        images = [...imagesContainer.querySelectorAll('.image')];
    shuffle(images).forEach(image => {
        imagesContainer.appendChild(image);
    });
});