Skip to content

v3.4.0

Compare
Choose a tag to compare
@dsc8x dsc8x released this 08 Jul 20:01
· 44 commits to master since this release

With this release, you can now include Sass files:

{
  loader: '@epegzz/sass-vars-loader',
  options: {
    files: [
      path.resolve(__dirname, 'path/to/utils.scss'), // <-- new
      path.resolve(__dirname, 'path/to/styles.json')
    ]
  }
}

This can be useful in case you want to use Sass functions in your JavaScript/JSON files, like this:

// utils.scss
@function semiTransparent($color) {
  @return rgba($color, 0.5);
}
// styles.json
{
  "backgroundColor": "semiTransparent(blue)"
}