1.0.5 • Published 9 years ago

emartech-node-sass-json-importer v1.0.5

Weekly downloads
2
License
MIT
Repository
github
Last release
9 years ago

node-sass-json-importer build status

JSON importer for node-sass. Allows @importing .json files in Sass files parsed by node-sass.

Usage

This module hooks into node-sass's importer api.

var sass = require('node-sass');
var jsonImporter = require('node-sass-json-importer');

// Example 1
sass.render({
  file: scss_filename,
  importer: jsonImporter,
  [, options..]
}, function(err, result) { /*...*/ });

// Example 2
var result = sass.renderSync({
  data: scss_content
  importer: [jsonImporter, someOtherImporter]
  [, options..]
});

sass-loader

import jsonImporter from 'node-sass-json-importer';

...
// Webpack config
{
  sassLoader: {
    importer: jsonImporter
  }
}

Thanks to

This module is based on the sass-json-vars gem, which unfortunately isn't compatible with node-sass.

1.0.5

9 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago