M
M
marcussx2020-07-29 21:19:41
Sass
marcussx, 2020-07-29 21:19:41

Why does parcel mangle classes in sass preprocessor?

Input code

.container {
  max-width: 1170px;
  margin: auto;
}


exit code
._container_589a6 {
  max-width: 1170px;
  margin: auto;
}


Why so, how to fix?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Darhild, 2020-07-30
@marcussx

It's about css modules. I am using postcss and the modular build is listed in postcss.config.js

{
  "modules": true
}

If changed to false, then the class names will be as usual. To be honest, I don’t know how this is organized for sass - look, maybe it’s also indicated somewhere with you.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question