{"_id":"@andarist/rollup-stream","_rev":"1-9ad3a050a7ca371a1ed423e0a27f592a","name":"@andarist/rollup-stream","dist-tags":{"latest":"2.0.0"},"versions":{"2.0.0":{"name":"@andarist/rollup-stream","version":"2.0.0","description":"a wrapper around Rollup that returns a stream instead of a Promise","main":"index.js","scripts":{"test":"mocha"},"repository":{"type":"git","url":"git+https://github.com/permutatrix/rollup-stream.git"},"keywords":["rollup","gulpfriendly"],"author":{"name":"Permutator","email":"permutatorem@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/permutatrix/rollup-stream/issues"},"homepage":"https://github.com/permutatrix/rollup-stream#readme","dependencies":{},"devDependencies":{"chai":"^3.4.1","mocha":"^2.3.4","rollup-plugin-hypothetical":"^1.0.1"},"gitHead":"81608ab929bcaf529abcb0b416605c935e282888","_id":"@andarist/rollup-stream@2.0.0","_npmVersion":"6.5.0","_nodeVersion":"11.8.0","_npmUser":{"name":"andarist","email":"mateuszburzynski@gmail.com"},"dist":{"integrity":"sha512-o270oVoghL/ynKYjPdh0pbJPgM0bFo9ela3QRflWsl8Wd9ND/GGbTSjUmlGOcOpgS/Ox6cYANFIYgQ9pCBvfCw==","shasum":"5fc7f1aeb5a696b074534d50cb4214e91b557d29","tarball":"https://registry.npmjs.org/@andarist/rollup-stream/-/rollup-stream-2.0.0.tgz","fileCount":4,"unpackedSize":8858,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJc2Xz8CRA9TVsSAnZWagAAzAUQAKTPztt4+5RngFWHiWwY\nuLYufjpm6f90j29CkPyAYmK04aA++PvfCwosx96QbsDF8fJIJSXMQxiXfWPJ\n/EO6s/J7PsvDWE/D1xN9ti/xV/+OmJ7xPsloFxdGFFSPhRbwGK8Z9FUxvqYx\nhRwjrXarGomW/5rOuIxavauFs6PHqSvOT4k/7Iw6rLl28lXLN7+0haXBGHrY\nqjg28AEDhA/+CH7MrbyCZdH9+34z8AZr1AeSMkc8v6QqEiscH6VtkuXt2qqK\n8OwV38zzw+Fa8ZDGXJPyl8vZFPCvQlPwSADFD2wtLxF4FiJyS0zp6a1HJVTY\nGRvooaoN44y/Hoe8qFMsMln6roQrmWgny1uLFXYpxbHKBN2XVrHYTP7l0b9j\n0YgLw5UJfm68u5EquTXg+9igE9XPyfFLNbdm/otcjDQ76yE1+0ps/RX2PXTn\nlGBBCfNEZJF2xcSVqC2epL6ARohrpS1zXeC+6tkvOT73eWZLuB0JwB+AWuQm\n3aRxhREO0W5l8GsWep0DNGGss2VO8UTaCGzr0DnWjMOufgs0g19n2H2tNfXB\nWTU4yrN2bZRWRfKS2YU5V9NEuHuCEXwcWKKFQ0IKnf3PvTVHvCzFTzJnxcOM\nuYjIP352sw7+fWlXF4ND196T87v563JKYNfKhzMo7TGBgQAsqCJb7I4tIr3n\nWX1m\r\n=21p8\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIE3/0ZorV7gEQ7/gk51/1rvu7+FFI0DIzS1BuOj0dsZ2AiBpqbJrbS/yTYiHNF5toHpscslGW0dW/aBhYpWKcnKjxA=="}]},"maintainers":[{"name":"andarist","email":"mateuszburzynski@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-stream_2.0.0_1557757180327_0.27670583943390525"},"_hasShrinkwrap":false}},"time":{"created":"2019-05-13T14:19:40.303Z","2.0.0":"2019-05-13T14:19:40.464Z","modified":"2022-04-04T13:57:30.749Z"},"maintainers":[{"name":"andarist","email":"mateuszburzynski@gmail.com"}],"description":"a wrapper around Rollup that returns a stream instead of a Promise","homepage":"https://github.com/permutatrix/rollup-stream#readme","keywords":["rollup","gulpfriendly"],"repository":{"type":"git","url":"git+https://github.com/permutatrix/rollup-stream.git"},"author":{"name":"Permutator","email":"permutatorem@gmail.com"},"bugs":{"url":"https://github.com/permutatrix/rollup-stream/issues"},"license":"MIT","readme":"# rollup-stream [![npm][npm-image]][npm-url] [![Dependency Status][david-image]][david-url] [![Build Status][travis-image]][travis-url]\nThis is a simple wrapper around [Rollup] that returns a readable stream instead\nof a Promise, like Browserify's bundle() method. It's designed to make using\nRollup with [gulp] easier, but if you find another use for it, go ahead!\n\nThe options object is passed to Rollup's rollup() and generate() methods. This\ncurrently works because there's no overlap between the names of the options\nthose methods take. Hopefully that won't change any time soon!\n\n## Installation\n```bash\nnpm install --save-dev rollup-stream\n```\n\n## Basic usage\n```js\nvar gulp = require('gulp'),\n    rollup = require('rollup-stream'),\n    source = require('vinyl-source-stream');\n\ngulp.task('rollup', function() {\n  return rollup({\n      input: './src/main.js'\n    })\n    \n    // give the file the name you want to output with.\n    .pipe(source('app.js'))\n    \n    // and output to ./dist/app.js as normal.\n    .pipe(gulp.dest('./dist'));\n});\n```\n\n## Usage with sourcemaps\n```js\nvar gulp = require('gulp'),\n    rollup = require('rollup-stream'),\n    sourcemaps = require('gulp-sourcemaps'),\n//  rename = require('gulp-rename'),\n    source = require('vinyl-source-stream'),\n    buffer = require('vinyl-buffer');\n\ngulp.task('rollup', function() {\n  return rollup({\n      input: './src/main.js',\n      sourcemap: true\n    })\n    \n    // point to the entry file.\n    .pipe(source('main.js', './src'))\n    \n    // buffer the output. most gulp plugins, including gulp-sourcemaps, don't support streams.\n    .pipe(buffer())\n    \n    // tell gulp-sourcemaps to load the inline sourcemap produced by rollup-stream.\n    .pipe(sourcemaps.init({loadMaps: true}))\n        \n        // transform the code further here.\n        \n    // if you want to output with a different name from the input file, use gulp-rename here.\n//  .pipe(rename('index.js'))\n    \n    // write the sourcemap alongside the output file.\n    .pipe(sourcemaps.write('.'))\n    \n    // and output to ./dist/main.js as normal.\n    .pipe(gulp.dest('./dist'));\n});\n```\n\n## Usage with caching\n```js\nvar gulp = require('gulp'),\n    rollup = require('rollup-stream'),\n    source = require('vinyl-source-stream');\n\nvar cache;\ngulp.task('rollup', function() {\n  return rollup({\n      input: './src/main.js',\n      cache: cache\n    })\n    \n    .on('bundle', function(bundle) {\n      cache = bundle;\n    })\n    \n    // after listening for the 'bundle' event, proceed as usual.\n    .pipe(source('app.js'))\n    .pipe(gulp.dest('./dist'));\n});\n\ngulp.task('watch', function() {\n  gulp.watch('./src/**/*.js', ['rollup']);\n});\n```\n\n## Usage with newer, older, or custom Rollup\n```js\nvar gulp = require('gulp'),\n    rollup = require('rollup-stream'),\n    source = require('vinyl-source-stream');\n\ngulp.task('rollup', function() {\n  return rollup({\n      input: './src/main.js',\n      rollup: require('rollup')\n    })\n    \n    // after passing options.rollup, proceed as usual.\n    .pipe(source('app.js'))\n    .pipe(gulp.dest('./dist'));\n});\n```\n\n## Usage with Rollup config file\n```js\nvar gulp = require('gulp'),\n    rollup = require('rollup-stream'),\n    source = require('vinyl-source-stream');\n\ngulp.task('rollup', function() {\n  return rollup('rollup.config.js')\n    .pipe(source('app.js'))\n    .pipe(gulp.dest('./dist'));\n});\n```\n\n\n[npm-url]: https://npmjs.org/package/rollup-stream\n[npm-image]: https://img.shields.io/npm/v/rollup-stream.svg\n[david-url]: https://david-dm.org/Permutatrix/rollup-stream\n[david-image]: https://img.shields.io/david/Permutatrix/rollup-stream/master.svg\n[travis-url]: https://travis-ci.org/Permutatrix/rollup-stream\n[travis-image]: https://img.shields.io/travis/Permutatrix/rollup-stream/master.svg\n\n[Rollup]: https://www.npmjs.com/package/rollup\n[gulp]: http://gulpjs.com/\n","readmeFilename":"README.md"}