Bootstrap columns stacking vertically on mobile device

后端 未结 2 1029
情书的邮戳
情书的邮戳 2020-11-28 00:05

I have a simple bootstrap grid layout. I do not want the columns to stack vertically even on small devices.

相关标签:
2条回答
  • 2020-11-28 00:09

    The columns are stacking vertically because you're using Bootstrap 4, and the -xs- infix is no longer used. Just use col-4..

      <div class="container border-show center-div">
        <div class="row">
          <div class="col-4 border-show">1</div>
          <div class="col-4 border-show">2</div>
          <div class="col-4 border-show">3</div>
        </div>
      </div>
    

    http://www.codeply.com/go/sCct2CzZte

    0 讨论(0)
  • 2020-11-28 00:19

    I can't quite make out the question because the HTML you posted does exactly what you want it to do: It never stacks the columns vertically for that row.

    Could you clarify what you're trying to ask? See How To Ask for a reference of how to ask good questions.

    0 讨论(0)
提交回复
热议问题