I have bootstrap working in a custom theme but cannot import unless the import is in main.scss:
this works:
theme/assets/sass/main.scss
@import "overrides.scss";
@import "node_modules/bootstrap/scss/bootstrap";
@import "node_modules/bootstrap/scss/functions";
but this doesn’t:
theme/assets/sass/overrides.scss
@import "node_modules/bootstrap/scss/functions";
“File to import not found or unreadable: node_modules/bootstrap/scss/_functions.”
If I put it in main.scss it imports but overrides.scss can’t see anything in it such as
"Undefined variable: “$grid-breakpoints”
overrides.scss can see variables such as $primary
and $secondary
but nothing in any other bootstrap import coming from main.scss.
Is there a better way to override bootstrap styles in a Hugo theme?