Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bootstrap 4.5 How can I change container grid-gutter-width

Under _variables.scss we can change $grid-gutter-width: 30px !default; for all components.

Now, I need to change it only for .container class:

Like:

.container {
    padding-left: 40px;
    padding-right: 40px;
}

Where I can manage this on BS 4.5?

like image 537
vishnu Avatar asked Dec 05 '25 14:12

vishnu


1 Answers

For the .container only...

.container {
   @include make-container(40px);
}

For the .container and the grid columns inside it...

.container {
   @include make-container(40px);
   @include make-grid-columns($grid-columns, 40px, $grid-breakpoints)
}

Codeply demo

like image 144
Zim Avatar answered Dec 08 '25 07:12

Zim



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!