D
D
Dp762020-08-04 11:58:31
Bootstrap
Dp76, 2020-08-04 11:58:31

How to make one card full width in Bootstrap's grid of cards?

We have a structure:

<div class="row row-cols-1 row-cols-md-2">
    <div class="col">
         <div class="card"></div>
   </div>
  <div class="col">
         <div class="card"></div>
  </div>
         ......
  <div class="col">
         <div class="card"></div>
    </div>
</div>


All this is beautifully rendered in one column on small screens and two on large ones. The task after the first two cards is to make a card (divs) for the entire width of the row. Yes, you can close the current row, open a new one to full width, and then start over again. Is there an option inside the given row to make the card full width?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Sharomet, 2020-08-04
@Dp76

<div class="row">
    <div class="col-md-6">
         <div class="card"></div>
   </div>
   <div class="col-md-6">
         <div class="card"></div>
  </div>
  <div class="col-12">
         <div class="card"></div>
  </div>
  <div class="col-md-6">
         <div class="card"></div>
    </div>
</div>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question