Is there a way to rearrange the columns' elements in a specific order when resizing to mobile? Here's the code snippet:
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet" />
<div class="container">
<div class="row">
<div class="col-sm-1">1</div>
<div class="col-sm-1">2</div>
<div class="col-sm-1">3</div>
<div class="col-sm-1">4</div>
<div class="col-sm-1">5</div>
</div>
<div class="row">
<div class="col-sm-1">6</div>
<div class="col-sm-1">7</div>
<div class="col-sm-1">8</div>
<div class="col-sm-1">9</div>
<div class="col-sm-1">10</div>
</div>
<div class="row">
<div class="col-sm-1">11</div>
<div class="col-sm-1">12</div>
<div class="col-sm-1">13</div>
<div class="col-sm-1">14</div>
<div class="col-sm-1">15</div>
</div>
</div>
On resizing, I want the order to be:
[1]
[2]
[6]
[7]
[11]
[12]
[3]
[8]
[13]
[4]
[9]
[14]
[5]
[10]
[15]
I've looked into using flex-column-reverse flex-md-row
, but it doesn't solve my issue. Any suggestions on how to achieve the desired order on resize?