Comparing version 2.0.0 to 2.0.3
{ | ||
"name": "sheetify", | ||
"version": "2.0.0", | ||
"description": "", | ||
"main": "sheetify.js", | ||
"version": "2.0.3", | ||
"description": "Modular CSS bundler", | ||
"scripts": { | ||
"test": "faucet test/*.js" | ||
"deps": "dependency-check . && dependency-check . --extra --no-dev", | ||
"deps:pkg": "ncu", | ||
"deps:update": "ncu -a", | ||
"test": "standard && npm run deps && faucet test/*.js", | ||
"test:cov": "standard && npm run deps && NODE_ENV=test istanbul cover test/index.js", | ||
"format": "standard --format" | ||
}, | ||
"author": "", | ||
"bin": { | ||
"sheetify": "bin.js" | ||
"sheetify": "bin/cli.js" | ||
}, | ||
"repository": "sheetify/sheetify", | ||
"keywords": [ | ||
"modular", | ||
"css", | ||
"bundle", | ||
"browserify", | ||
"css-modules" | ||
], | ||
"license": "MIT", | ||
"dependencies": { | ||
"once": "~1.3.0", | ||
"cliclopts": "^1.1.1", | ||
"minimist": "^1.2.0", | ||
"noop2": "^2.0.0", | ||
"style-deps": "^2.0.1", | ||
"style-resolve": "0.0.0", | ||
"subarg": "0.0.1", | ||
"xtend": "~2.1.2" | ||
"xtend": "^4.0.0" | ||
}, | ||
"devDependencies": { | ||
"tape": "~2.4.2", | ||
"wrap-selectors": "~0.1.0", | ||
"faucet": "0.0.1" | ||
"concat-stream": "^1.5.0", | ||
"dependency-check": "^2.5.0", | ||
"faucet": "^0.0.1", | ||
"istanbul": "^0.3.19", | ||
"npm-check-updates": "^2.2.0", | ||
"standard": "^5.2.1", | ||
"tape": "^4.2.0", | ||
"through2": "^2.0.0", | ||
"wrap-selectors": "^0.1.0" | ||
} | ||
} |
@@ -1,20 +0,88 @@ | ||
# sheetify # | ||
# sheetify | ||
<img | ||
alt="sheetify logo" | ||
height="100" | ||
style="max-width: 100%" | ||
data-canonical-src="https://github.com/sheetify/logo" | ||
src="https://raw.githubusercontent.com/sheetify/logo/master/512v6.png"> | ||
A module bundler for CSS that works with [npm](http://npmjs.org/) modules | ||
like [browserify](http://browserify.org/) does – including sourcemap support! | ||
[![NPM version][npm-image]][npm-url] | ||
[![build status][travis-image]][travis-url] | ||
[![Test coverage][codecov-image]][codecov-url] | ||
[![Downloads][downloads-image]][downloads-url] | ||
[![js-standard-style][standard-image]][standard-url] | ||
## Command-Line Usage ## | ||
Modular CSS bundler. Works with [npm](http://npmjs.org/) modules like | ||
[browserify](http://browserify.org/) does. | ||
``` bash | ||
Usage: | ||
__Features__ | ||
- source map support | ||
- minification | ||
- rich plugin ecosystem | ||
- streaming interface | ||
- easily extensible | ||
sheetify [entry file] {OPTIONS} | ||
## Usage | ||
__cli__ | ||
```txt | ||
sheetify - Modular CSS bundler | ||
Usage: sheetify [options] [entry file] | ||
Options: | ||
-h, --help Output usage information | ||
-v, --version Output version number | ||
-t, --transform Include a sheetify transform | ||
-m, --modifier Include a sheetify modifier | ||
-c, --compress Compress final output | ||
-d, --debug Inline CSS sourcemaps | ||
--transform, -t Include a sheetify transform. | ||
--modifier, -m Include a sheetify modifier. | ||
--compress, -c Compress final output. | ||
--version, -v Output version information and quit. | ||
--debug, -d Inline CSS sourcemaps to final output. | ||
Examples: | ||
$ sheetify index.css > bundle.css # Bundle index.css to bundle.css | ||
$ sheetify -cd index.css # Compress and include source maps | ||
Docs: https://github.com/sheetify/sheetify | ||
Bugs: https://github.com/sheetify/sheetify/issues | ||
``` | ||
__api__ | ||
```js | ||
const sheetify = require('sheetify') | ||
const bundler = sheetify('./index.css') | ||
bundler.bundle().pipe(process.stdout) | ||
``` | ||
## Options | ||
### transform | ||
[tbi] | ||
### modifier | ||
[tbi] | ||
### compress | ||
[tbi] | ||
### debug | ||
[tbi] | ||
## API | ||
### bundler = sheetify(entry) | ||
[tbi] | ||
### bundler.bundle(cb(err, res)) | ||
[tbi] | ||
## License | ||
[MIT](https://tldrlegal.com/license/mit-license) | ||
[npm-image]: https://img.shields.io/npm/v/sheetify.svg?style=flat-square | ||
[npm-url]: https://npmjs.org/package/sheetify | ||
[travis-image]: https://img.shields.io/travis/sheetify/sheetify/master.svg?style=flat-square | ||
[travis-url]: https://travis-ci.org/sheetify/sheetify | ||
[codecov-image]: https://img.shields.io/codecov/c/github/sheetify/sheetify/master.svg?style=flat-square | ||
[codecov-url]: https://codecov.io/github/sheetify/sheetify | ||
[downloads-image]: http://img.shields.io/npm/dm/sheetify.svg?style=flat-square | ||
[downloads-url]: https://npmjs.org/package/sheetify | ||
[standard-image]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square | ||
[standard-url]: https://github.com/feross/standard |
@@ -1,15 +0,12 @@ | ||
var test = require('tape') | ||
var exec = require('child_process').exec | ||
var fs = require('fs') | ||
const exec = require('child_process').exec | ||
const test = require('tape') | ||
const fs = require('fs') | ||
var BIN = require.resolve('../bin.js') | ||
const BIN = require.resolve('../bin/cli.js') | ||
const expected = fs.readFileSync(__dirname + '/concat-expected.css', 'utf8') | ||
var expected = fs.readFileSync(__dirname + '/concat-expected.css', 'utf8') | ||
test('works', function(t) { | ||
test('works', function (t) { | ||
t.plan(2) | ||
exec(BIN + ' concat.css', { | ||
cwd: __dirname | ||
}, function(err, stdout, stderr) { | ||
const opts = { cwd: __dirname } | ||
exec(BIN + ' concat.css', opts, function (err, stdout, stderr) { | ||
t.ifError(err) | ||
@@ -16,0 +13,0 @@ t.equal(stdout.trim(), expected.trim()) |
@@ -1,5 +0,5 @@ | ||
module.exports = function(file) { | ||
return function(style, next) { | ||
module.exports = function (file) { | ||
return function (style, next) { | ||
return next(null, style) | ||
} | ||
} |
@@ -1,12 +0,17 @@ | ||
var sheetify = require('../sheetify') | ||
var wrap = require('wrap-selectors') | ||
var test = require('tape') | ||
var fs = require('fs') | ||
const concat = require('concat-stream') | ||
const wrap = require('wrap-selectors') | ||
const test = require('tape') | ||
const fs = require('fs') | ||
test('basic', function(t) { | ||
var expects = fs.readFileSync(__dirname + '/fixtures/basic-expected.css') | ||
var bundler = sheetify(__dirname + '/fixtures/basic.css') | ||
require('./concat') | ||
bundler.transform(function(file) { | ||
return function(ast, next) { | ||
const sheetify = require('..') | ||
test('basic', function (t) { | ||
t.plan(2) | ||
const expects = fs.readFileSync(__dirname + '/fixtures/basic-expected.css') | ||
const bundler = sheetify(__dirname + '/fixtures/basic.css') | ||
bundler.transform(function (file) { | ||
return function (ast, next) { | ||
next(null, wrap()(ast)) | ||
@@ -16,15 +21,15 @@ } | ||
bundler.bundle(function(err, output) { | ||
bundler.bundle(function (err, output) { | ||
t.ifError(err, 'bundled without error') | ||
t.equal(String(expects).trim(), output.trim(), 'expected output') | ||
t.end() | ||
}) | ||
}) | ||
test('imports', function(t) { | ||
var expects = fs.readFileSync(__dirname + '/fixtures/imports-expected.css') | ||
var bundler = sheetify(__dirname + '/fixtures/imports.css') | ||
test('stream', function (t) { | ||
t.plan(1) | ||
const expects = fs.readFileSync(__dirname + '/fixtures/basic-expected.css') | ||
const bundler = sheetify(__dirname + '/fixtures/basic.css') | ||
bundler.transform(function(file) { | ||
return function(ast, next) { | ||
bundler.transform(function (file) { | ||
return function (ast, next) { | ||
next(null, wrap()(ast)) | ||
@@ -34,7 +39,22 @@ } | ||
bundler.bundle(function(err, output) { | ||
bundler.bundle().pipe(concat(function (css) { | ||
t.equal(expects.toString().trim(), css.toString().trim()) | ||
})) | ||
}) | ||
test('imports', function (t) { | ||
t.plan(2) | ||
const expects = fs.readFileSync(__dirname + '/fixtures/imports-expected.css') | ||
const bundler = sheetify(__dirname + '/fixtures/imports.css') | ||
bundler.transform(function (file) { | ||
return function (ast, next) { | ||
next(null, wrap()(ast)) | ||
} | ||
}) | ||
bundler.bundle(function (err, output) { | ||
t.ifError(err, 'bundled without error') | ||
t.equal(String(expects).trim(), output.trim(), 'expected output') | ||
t.end() | ||
}) | ||
}) |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No contributors or author data
MaintenancePackage does not specify a list of contributors or an author in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
11728
24
89
9
287
3
+ Addedcliclopts@^1.1.1
+ Addedminimist@^1.2.0
+ Addednoop2@^2.0.0
+ Addedcliclopts@1.1.1(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addednoop2@2.0.0(transitive)
+ Addedonce@1.4.0(transitive)
+ Addedxtend@2.2.04.0.2(transitive)
- Removedonce@~1.3.0
- Removedstyle-resolve@0.0.0
- Removedsubarg@0.0.1
- Removedminimist@0.0.10(transitive)
- Removedonce@1.3.3(transitive)
- Removedsubarg@0.0.1(transitive)
Updatedxtend@^4.0.0