question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

v4 - Error: $color: 'theme-color("primary")' is not a color for `darken'

See original GitHub issue

i have switch to v4 instead of the alphav6

npm install bootstrap@4.0.0-beta

and when i compile i get

Error: $color: ‘theme-color(“primary”)’ is not a color for `darken’ on line 168 of sass/bootstrap/_variables.scss

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:13
  • Comments:14 (2 by maintainers)

github_iconTop GitHub Comments

17reactions
sjdeerecommented, Aug 11, 2017

if you use a custom override … make sure its below functions";

@import “bootstrap/functions”; @import “bootstrap/custom”; @import “bootstrap/variables”;

i think thats what i did wrong. i was doing @import “bootstrap/custom”; @import “bootstrap/functions”; @import “bootstrap/variables”;

9reactions
mdocommented, Aug 11, 2017

Lots of breaking changes from latest alpha to beta, as was to be expected and was the main reason for constantly holding off on pushing a beta.

Include the _functions.scss file if you haven’t yet and you’ll be good to go.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bootstrap SCSS: $color: theme-color("primary") is not a color
The problem is the order in which you have imported the files. Please try this way and see if it works. First import...
Read more >
Error: Failed to compile .scss file - $color - Board index
Error : $color: theme-color("primary") is not a color. * , * 179 | $link-hover-color: darken($link-color, 15%) !default; ...
Read more >
Discover how to override theme colors in Bootstrap 5 using Sass
Bootstrap 5 utilizes both theme-color("primary") and $primary color defintions. This article details how to override and extend the ...
Read more >
Theming Bootstrap
Customize Bootstrap 4 with our new built-in Sass variables for global style ... @function theme-color($key: "primary") { @return map-get($theme-colors, ...
Read more >
theme-color - HTML: HyperText Markup Language | MDN
Image credit: from Icons & Browser Colors, created and shared by Google and used according to terms described in the Creative Commons 4.0...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found