Socket
Socket
Sign inDemoInstall

node-sass

Package Overview
Dependencies
Maintainers
2
Versions
148
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-sass - npm Package Compare versions

Comparing version 0.6.6 to 0.6.7

10

lib/render.js

@@ -23,9 +23,7 @@

emitter.emit('write', err, options.outFile, css);
if (options.stdout) {
emitter.emit('log', css);
}
emitter.emit('render', css);
});
if (options.stdout) {
emitter.emit('log', css);
}
emitter.emit('render', css);
},

@@ -32,0 +30,0 @@ error: function(error) {

2

package.json

@@ -5,3 +5,3 @@ {

"description": "wrapper around libsass",
"version": "0.6.6",
"version": "0.6.7",
"homepage": "https://github.com/andrew/node-sass",

@@ -8,0 +8,0 @@ "keywords": [

var binding;
var fs = require('fs');
var path = require('path');
try {

@@ -66,7 +67,7 @@ if (fs.realpathSync(__dirname + '/build')) {

if (options.file !== undefined && options.file !== null) {
return binding.renderFile(options.file, options.success, options.error, newOptions.paths.join(':'), newOptions.style, newOptions.comments);
return binding.renderFile(options.file, options.success, options.error, newOptions.paths.join(path.delimiter), newOptions.style, newOptions.comments);
}
//Assume data is present if file is not. binding/libsass will tell the user otherwise!
return binding.render(options.data, options.success, options.error, newOptions.paths.join(":"), newOptions.style);
return binding.render(options.data, options.success, options.error, newOptions.paths.join(path.delimiter), newOptions.style);
};

@@ -73,0 +74,0 @@

@@ -5,6 +5,6 @@ var path = require('path'),

exec = require('child_process').exec,
sass = require(path.join(__dirname, '..', 'sass')),
cli = require(path.join(__dirname, '..', 'lib', 'cli')),
sass = require('../sass'),
cli = require('../lib/cli'),
cliPath = path.resolve(__dirname, '..', 'bin', 'node-sass'),
cliPath = path.resolve(__dirname, '../bin/node-sass'),
sampleFilename = path.resolve(__dirname, 'sample.scss');

@@ -31,3 +31,3 @@

it('should print help when run with no arguments', function(done) {
exec(cliPath, function(err, stdout, stderr) {
exec('node ' + cliPath, function(err, stdout, stderr) {
done(assert(stderr.indexOf('Compile .scss files with node-sass') === 0));

@@ -40,3 +40,3 @@ });

exec(cliPath + ' ' + sampleFilename, {
exec('node ' + cliPath + ' ' + sampleFilename, {
cwd: __dirname

@@ -53,5 +53,5 @@ }, function(err, stdout, stderr) {

it('should compile sample.scss to ../out.css', function(done) {
var resultPath = path.resolve(__dirname, '..', 'out.css');
var resultPath = path.resolve(__dirname, '../out.css');
exec(cliPath + ' ' + sampleFilename + ' ../out.css', {
exec('node ' + cliPath + ' ' + sampleFilename + ' ../out.css', {
cwd: __dirname

@@ -69,5 +69,5 @@ }, function(err, stdout, stderr) {

var emitter = cli([
'--include-path', __dirname + '/lib',
'--include-path', __dirname + '/functions',
__dirname + '/include_path.scss'
'--include-path', path.join(__dirname, 'lib'),
'--include-path', path.join(__dirname, 'functions'),
path.join(__dirname, 'include_path.scss')
]);

@@ -77,3 +77,3 @@ emitter.on('error', done);

assert.equal(css.trim(), 'body {\n background: red;\n color: blue; }');
fs.unlink(process.cwd() + '/include_path.css', done);
fs.unlink(path.resolve(process.cwd(), 'include_path.css'), done);
});

@@ -83,7 +83,7 @@ });

it('should compile with the --output-style', function(done){
var emitter = cli(['--output-style', 'compressed', __dirname + '/sample.scss']);
var emitter = cli(['--output-style', 'compressed', path.join(__dirname, 'sample.scss')]);
emitter.on('error', done);
emitter.on('render', function(css){
assert.equal(css, expectedSampleCompressed);
fs.unlink(process.cwd() + '/sample.css', done);
fs.unlink(path.resolve(process.cwd(), 'sample.css'), done);
});

@@ -93,7 +93,7 @@ });

it('should compile with the --source-comments option', function(done){
var emitter = cli(['--source-comments', 'none', __dirname + '/sample.scss']);
var emitter = cli(['--source-comments', 'none', path.join(__dirname, 'sample.scss')]);
emitter.on('error', done);
emitter.on('render', function(css){
assert.equal(css, expectedSampleNoComments);
fs.unlink(process.cwd() + '/sample.css', done);
fs.unlink(path.resolve(process.cwd(), 'sample.css'), done);
});

@@ -103,4 +103,4 @@ });

it('should write the output to the file specified with the --output option', function(done){
var resultPath = path.resolve(__dirname, '..', 'output.css');
var emitter = cli(['--output', resultPath, __dirname + '/sample.scss']);
var resultPath = path.join(__dirname, '../output.css');
var emitter = cli(['--output', resultPath, path.join(__dirname, 'sample.scss')]);
emitter.on('error', done);

@@ -107,0 +107,0 @@ emitter.on('write', function(css){

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc