我想打乱我div
桌子上的单元格。我尝试使用该.shuffle()
插件,但无法使其工作。这是我的代码:
<div class="sprites">
<div class="row">
<span id="draggable0" class="draggable"></span>
<span id="draggable1" class="draggable"></span>
<span id="draggable2" class="draggable"></span>
</div>
<div class="row">
<span id="draggable3" class="draggable"></span>
<span id="draggable4" class="draggable"></span>
<span id="draggable5" class="draggable"></span>
</div>
<div class="row">
<span id="draggable6" class="draggable"></span>
<span id="draggable7" class="draggable"></span>
<span id="draggable8" class="draggable"></span>
</div>
</div>
这就是我尝试洗牌的方式:
$(document).ready(function () {
$('.sprites').shuffle();
});
你知道我怎么能洗牌所有这些东西吗?