Error:-
ERROR in ./src/_metronic/assets/sass/style.scss (./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[7].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[7].use[2]!./node_modules/resolve-url-loader/index.js??ruleSet[1].rules[1].oneOf[7].use[3]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[7].use[4]!./src/_metronic/assets/sass/style.scss)
Module build failed (from ./node_modules/sass-loader/dist/cjs.js):
SassError: Undefined variable.
â•·
55 │ "primary": $primary-text-emphasis-dark,
│ ^^^^^^^^^^^^^^^^^^^^^^^^^^^
╵
node_modules\bootstrap\scss\_maps.scss 55:16 @import
src\_metronic\assets\sass\_init.scss 19:9 @import
src\_metronic\assets\sass\style.scss 9:9 root stylesheet
the metronic version :- 10.1.0
the current node version :- v18.18.0
the npm version :- 10.1.0
Hi,
The latest Metronic version is mentioned as 8.2.1, not 10.1.0.
The error points to an issue in the _maps.scss file of Bootstrap (node_modules/bootstrap/scss/_maps.scss). It suggests an undefined variable, which might be due to changes in variable names or structures between Bootstrap versions.
Try to align the Bootstrap version used in your project with the one compatible with your package.json file, find the Bootstrap dependency and set it to a version that is known to work well with your Metronic version. Try to reduce the Bootstrap version.
After modifying the package.json file, run the npm install command to update your dependencies and rebuild the assets.
Thanks