1.0.0 • Published 8 years ago

gobble-sass-file v1.0.0

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

gobble-sass-file

File-level trasformer plugin for scss and sass. Unlike gobble-sass combines all scss or sass files into a single css file, this plugin does a 1-to-1 transformation that also can use includes and imports.

Primary use is for component-level css where you want to write sass or scss but want to keep the output css separated on a per-file basis.

Installation

First, you need to have gobble installed - see the gobble readme for details. Then,

npm i -D gobble-flatten

Usage

gobblefile.js

const components = gobble('src/components')
	.transform( sass, {
        // you can still use common include paths:
		includePaths: [ join(process.cwd(), 'src/scss/include') ]
	})
	.transform('babel', {
		sourceMaps: true,
		blacklist: ['es6.modules', 'strict']
	})
	.transform( makeComponent )
	.transform('ractive', { type: 'es6' });

Tests

Uses gobble-test example based testing. Run via:

npm test

License

MIT. Copyright 2016 Marty Nelson