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.

Error: $color: "var(--bs-primary-rgb)" is not a color for `rgba' in v5.1.0

See original GitHub issue

I try to compile in latest v5.1.0 So, I get error as below. have i wrong anything?

Error: $color: “var(–bs-primary-rgb)” is not a color for `rgba’ on line 41 of C:/xampp/htdocs/myproject/sass/bootstrap/_functions.scss from line 2 of C:\xampp\htdocs\myproject\sass\stylesheet.scss

My stylesheet.scss

@import "bootstrap/functions";
@import "bootstrap/variables";
@import "bootstrap/mixins";
@import "bootstrap/vendor/rfs";

// Initialize
@import "variables";
@import "mixins";

// Core CSS
@import "reset";
@import "helpers";
@import "layouts";

// Content Blocks
@import "elements";
@import "social-icons";
@import "extras";

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:45 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
softwareacommented, Sep 6, 2021

For all those using Visual Studio 2019 and Mad Kristensen’s “Web Compiler” extension: yes, this extension is five years old. I uninstalled this extension and instead installed another extension called “Sass Compiler”, which is from Mad Kristensen as well. Using this new extension, the errors with BS v5.1.0 went away.

2reactions
icebitscommented, Aug 10, 2021

For those using Web Compiler extension. The default node-sass v4.9.3 not able to compile BS v5.1.0 anymore. Please manually download latest node-sass (at least v5.0) using npm, then replace node-sass folder in C:\Users<your id>\AppData\Local\Temp\WebCompiler1.12.394\node_modules. You also need to upgrade/replace existing Web Compiler’s node.exe (located outside of node_modules folder), you can find the file after install node.js x64 for windows. Must use x64 executable file.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error: $color: "var(--bs-primary-rgb)" is not a color for `rgba' in v5.1.0 ...
Error : $color: "var(--bs-primary-rgb)" is not a color for `rgba' in v5.1.0 - JavaScript bootstrap. I try to compile in latest v5.1.0 So,...
Read more >
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 >
Color · Bootstrap v5.3
These new colors are available through Sass and CSS variables (but not our color maps or ... green, blue values for use in...
Read more >
Quick and Dirty Bootstrap Overrides at Runtime - CSS-Tricks
Bootstrap wants to be generated server-side and it does not like having ... Sass won't compile if you set color variables as CSS...
Read more >
Bootstrap 5 Colors - examples & tutorial
text-opacity-* utilities and CSS variables for text utilities, .text-black-50 and .text-white-50 are deprecated as of Bootstrap v5.1.0. They'll be removed in ...
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