How do you customize Bootstrap with Sass?

$primary: #6f42c1;
$border-radius: 0.75rem;

@import "node_modules/bootstrap/scss/bootstrap";

The variables must be set before the import. Compile with Sass (npx sass custom.scss custom.css). Current Dart Sass shows a deprecation warning for @import, but the build works. See Bootstrap Customization.


Learn more about the similar topics:
Tutorials
No Content Found.
Exercises & Assignments
No Content Found.
Interview Questions & Answers
No Content Found.