How to put offset in bootstrap4 beta. col-offset-"offset value"
is not working for me. How can I solve this? Thank you
Asked
Active
Viewed 184 times
0

Self
- 497
- 1
- 6
- 19
2 Answers
0
col-{selector}-offset-{value}
has been replaced with ml-auto
or mr-auto
class, depending on which side you want for margin
to start.
You should read the documentation next time when trying out new versions of frameworks.

Vladimir Jovanović
- 5,143
- 5
- 21
- 42
-1
We dont do offset instead we give a margin , bootstrap 4 uses flex so its a little bit different from previous versions alpha-4 included. we use .mt-auto to give remaining coloums for margin or else we can do different margin for different screen sizes
<div class="row">
<div class="col-md-4">.col-md-4</div>
<div class="col-md-4 ml-auto">.col-md-4 .ml-auto</div>
</div>
It's there in the bootstrap 4 beta documentation https://getbootstrap.com/docs/4.0/layout/grid/#offsetting-columns

Mayank Singh Fartiyal
- 867
- 1
- 11
- 26
-
That's the alpha, not [beta documentation](http://getbootstrap.com) – Carol Skelly Aug 29 '17 at 11:18
-
This was deprecated in `Bootstrap v4 beta` , `offset-md` was only available in `Bootstrap v4 alpha`. – Vladimir Jovanović Aug 29 '17 at 11:18
-
@VladimirJovanović My bad i changed the answer – Mayank Singh Fartiyal Aug 29 '17 at 11:26
-
@ZimSystem sorry totally left my mind. – Mayank Singh Fartiyal Aug 29 '17 at 11:26