Skip to content

haithembelhaj/compass-importer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

compass-importer

A node-sass importer for compass. This package will download an uptodate compass-mixin and link all declarations of @import 'compass' to the mixins. The Compass will also automagically update the compass-mixin from Github. The result is all the power of compass with the speed of libsass.

Install

$ npm install --save-dev compass-importer

Usage

You can use this importer in node-sass or any project that depends on node-sass. the only thing you need to do to make this work is add the importer to the options and include the '.compass' folder.

node-sass

var sass = require('node-sass');
var compass = require('compass-importer')

sass.render({
  data: '@import "compass"; .transition { @include transition(all); }',
  importer: compass
});

grunt-sass

var compass = require('compass-importer')


grunt.initConfig({
    
    sass:{
       
        options: {
            importer: compass
        },
        ...        
    }

})

gulp-sass

var gulp = require('gulp')
var sass = require('gulp-sass')
var compass = require('compass-importer')


gulp.task('sass', function()
{
    return gulp.src('sass/**/*.scss')
      .pipe(sass({ importer: compass }).on('error', sass.logError))
      .pipe(gulp.dest('./css'));

});

License

MIT

About

A node-sass compass importer

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published