irispixel/vscode-dartsass

Plugin does not use .browserslistrc when compiling Bootstrap 5

Opened this issue · 2 comments

'Visual Studio Code' and 'DartJS Sass Compiler and Sass Watcher' current versions.

I've downloaded Bootstrap 5 (from https://github.com/twbs/bootstrap/releases/download/v5.0.0/bootstrap-5.0.0-dist.zip), unzipped, opened directory bootstrap-5.0.0 and file scss\bootstrap.scss.

Bootstrap 5 sources contain .browserslistrc file.

The compiled bootstrap.css differs from official bootstrap.css. It contains all possible browser prefixes. For example:

.row {
  --bs-gutter-x: 1.5rem;
  --bs-gutter-y: 0;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
  margin-top: calc(var(--bs-gutter-y) * -1);
  margin-right: calc(var(--bs-gutter-x) / -2);
  margin-left: calc(var(--bs-gutter-x) / -2);
}

instead of

.row {
  --bs-gutter-x: 1.5rem;
  --bs-gutter-y: 0;
  display: flex;
  flex-wrap: wrap;
  margin-top: calc(var(--bs-gutter-y) * -1);
  margin-right: calc(var(--bs-gutter-x) / -2);
  margin-left: calc(var(--bs-gutter-x) / -2);
}

yes it would be great to use .browserslistrc instead of ide settings!

in the meantime it's easy to add '>= 0.5% and last 2 major versions and not Explorer <= 11 and not dead' in the settings and choose this one as default

This seems like a very important feature.

I will look into this later over the weekend to see how the plugin automatically reads .browserlistrc