{"_id":"rollup-plugin-natives","_rev":"678645","name":"rollup-plugin-natives","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","dist-tags":{"latest":"0.7.5"},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"time":{"modified":"2021-08-29T22:15:52.000Z","created":"2018-07-25T14:36:06.894Z","0.7.5":"2021-08-29T22:13:38.780Z","0.7.4":"2021-08-29T21:32:15.185Z","0.7.3":"2021-06-30T09:21:15.969Z","0.7.2":"2021-02-11T13:52:53.318Z","0.7.1":"2021-01-14T21:56:22.984Z","0.7.0":"2021-01-14T20:31:49.699Z","0.6.0":"2020-09-13T06:49:18.192Z","0.5.0":"2018-07-25T14:36:06.894Z"},"users":{},"author":{"name":"Daniel Cohen Gindi"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"versions":{"0.7.5":{"name":"rollup-plugin-natives","version":"0.7.5","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^10.0.0","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.32.0","husky":"^7.0.2","pinst":"^2.1.6"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./","_postinstall":"husky install","prepublishOnly":"pinst --disable","postpublish":"pinst --enable"},"gitHead":"afb65d2a21ac6bbde54cdd71c3e57403ef8db13f","_id":"rollup-plugin-natives@0.7.5","_nodeVersion":"16.5.0","_npmVersion":"6.14.13","dist":{"shasum":"98731534ca1d3616b72c418bd655620c41bc597c","size":4891,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.5.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.5_1630275218663_0.6669319966921166"},"_hasShrinkwrap":false,"publish_time":1630275218780,"_cnpm_publish_time":1630275218780},"0.7.4":{"name":"rollup-plugin-natives","version":"0.7.4","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^10.0.0","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.32.0","husky":"^7.0.2","pinst":"^2.1.6"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./","_postinstall":"husky install","prepublishOnly":"pinst --disable","postpublish":"pinst --enable"},"gitHead":"f8453e518242aedccb76b2a381caf1dd902f8caa","_id":"rollup-plugin-natives@0.7.4","_nodeVersion":"16.5.0","_npmVersion":"6.14.13","dist":{"shasum":"fa887e0d7a1df8a223695cf68e16c5ecb2b1ec17","size":4726,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.4.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.4_1630272735046_0.0025016792387886344"},"_hasShrinkwrap":false,"publish_time":1630272735185,"_cnpm_publish_time":1630272735185},"0.7.3":{"name":"rollup-plugin-natives","version":"0.7.3","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^10.0.0","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.29.0","husky":"^6.0.0","pinst":"^2.1.6"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./","_postinstall":"husky install","prepublishOnly":"pinst --disable","postpublish":"pinst --enable"},"gitHead":"cf2a5931683f925554802810316d314be3a47fcf","_id":"rollup-plugin-natives@0.7.3","_nodeVersion":"14.15.4","_npmVersion":"6.14.10","dist":{"shasum":"c6791857a4fc4921cd30259f067e12165d726668","size":4772,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.3.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.3_1625044875821_0.24896235225697727"},"_hasShrinkwrap":false,"publish_time":1625044875969,"_cnpm_publish_time":1625044875969},"0.7.2":{"name":"rollup-plugin-natives","version":"0.7.2","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^9.1.0","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.19.0","husky":"^4.3.8","pinst":"^2.1.4"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./","_postinstall":"husky install","prepublishOnly":"pinst --disable","postpublish":"pinst --enable"},"gitHead":"95cfbfb356675473915ca11bb32bf24f94ed0111","_id":"rollup-plugin-natives@0.7.2","_nodeVersion":"14.15.4","_npmVersion":"6.14.10","dist":{"shasum":"b3a2f8fa66a17115f23bbfde71f70c87517646f9","size":4765,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.2.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.2_1613051573191_0.8342328095055624"},"_hasShrinkwrap":false,"publish_time":1613051573318,"_cnpm_publish_time":1613051573318},"0.7.1":{"name":"rollup-plugin-natives","version":"0.7.1","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^9.0.1","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.17.0","husky":"^4.3.7"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./"},"gitHead":"00bcb660d993eaed820ef9313e53b3eeebda22cb","_id":"rollup-plugin-natives@0.7.1","_nodeVersion":"12.18.3","_npmVersion":"6.14.6","dist":{"shasum":"e9ae4d06fa0a8da3ce36ee2efe5060d55f830c2d","size":4632,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.1.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.1_1610661382792_0.26055250903469007"},"_hasShrinkwrap":false,"publish_time":1610661382984,"_cnpm_publish_time":1610661382984},"0.7.0":{"name":"rollup-plugin-natives","version":"0.7.0","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^9.0.1","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.17.0","husky":"^4.3.7"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./"},"gitHead":"7c0ec6b55391534a1899e7425e28b1b58f585c66","_id":"rollup-plugin-natives@0.7.0","_nodeVersion":"12.18.3","_npmVersion":"6.14.6","dist":{"shasum":"5eefcbddcf3f689fb50b8e3cffa0f98c7b5a8382","size":4552,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.7.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.7.0.tgz"},"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.7.0_1610656309554_0.9830471421802789"},"_hasShrinkwrap":false,"publish_time":1610656309699,"_cnpm_publish_time":1610656309699},"0.6.0":{"name":"rollup-plugin-natives","version":"0.6.0","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","peerDependencies":{"rollup":">=0.56.0"},"dependencies":{"fs-extra":"^9.0.1","magic-string":"^0.25.7"},"devDependencies":{"eslint":"^7.9.0","husky":"^4.3.0"},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","scripts":{"lint":"eslint -f codeframe ./","lint-fix":"eslint -f codeframe --fix ./"},"gitHead":"5d3ccf7407b86be522175aa5d5d9843290e7404f","_id":"rollup-plugin-natives@0.6.0","_nodeVersion":"12.13.0","_npmVersion":"6.12.0","dist":{"shasum":"7a8544311da4e16bb780101e5e70293ca0d42776","size":4429,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.6.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.6.0.tgz"},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.6.0_1599979758056_0.31581677169735545"},"_hasShrinkwrap":false,"publish_time":1599979758192,"_cnpm_publish_time":1599979758192},"0.5.0":{"name":"rollup-plugin-natives","version":"0.5.0","description":"Extract native modules (.node files) while creating a rollup bundle and put them in one place","main":"src/index.js","files":["src","README.md"],"peerDependencies":{"rollup":">=0.56.0"},"dependencies":{},"devDependencies":{},"repository":{"type":"git","url":"git+https://github.com/danielgindi/rollup-plugin-natives.git"},"author":{"name":"Daniel Cohen Gindi"},"license":"MIT","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","gitHead":"4d1b5fd484c14fa0439e1de1154ac3565efe70d3","_id":"rollup-plugin-natives@0.5.0","_npmVersion":"6.1.0","_nodeVersion":"10.6.0","_npmUser":{"name":"danielgindi","email":"danielgindi@gmail.com"},"dist":{"shasum":"11fb630922a01d615c3f0c7654f2efcd20579e65","size":3817,"noattachment":false,"key":"/rollup-plugin-natives/-/rollup-plugin-natives-0.5.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/rollup-plugin-natives/download/rollup-plugin-natives-0.5.0.tgz"},"maintainers":[{"name":"danielgindi","email":"danielgindi@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-plugin-natives_0.5.0_1532529366803_0.3930107819447992"},"_hasShrinkwrap":false,"publish_time":1532529366894,"_cnpm_publish_time":1532529366894}},"readme":"# rollup-plugin-natives\n\n[![npm Version](https://badge.fury.io/js/rollup-plugin-natives.png)](https://npmjs.org/package/rollup-plugin-natives)\n\nExtract native modules (.node files) while creating a rollup bundle and put them in one place\"\n\n\n## Installation\n\n```bash\nnpm install --save-dev rollup-plugin-natives\n```\n\n\n## Usage\n\nIn some cases you have native dependencies (usually required by `bindings` or `node-pre-gyp`) \nand you have to put them somewhere accessible to the rolled-up bundle.  \nThis package is just for doing exactly this.\n\n```js\n// rollup.config.js\nimport nativePlugin from 'rollup-plugin-natives';\n\nexport default {\n    input: 'main.js',\n    output: {\n        file: 'dist/bundle.js',\n        format: 'cjs'\n    },\n    plugins: [\n        nativePlugin({\n            // Where we want to physically put the extracted .node files\n            copyTo: 'dist/libs',\n\n            // Path to the same folder, relative to the output bundle js\n            destDir: './libs',\n\n            // Use `dlopen` instead of `require`/`import`.\n            // This must be set to true if using a different file extension that '.node'\n            dlopen: false,\n\n            // Modify the final filename for specific modules\n            // A function that receives a full path to the original file, and returns a desired filename\n            map: (modulePath) => 'filename.node',\n\n            // Or a function that returns a desired file name and a specific destination to copy to\n            map: (modulePath) => { name: 'filename.node', copyTo: 'C:\\\\Dist\\\\libs\\\\filename.node' },\n\n            // Generate sourcemap\n            sourcemap: true\n        })\n    ]\n};\n```\n\n## License\n\nMIT\n\n## About...\n\nThis plugin was created by me and shared with you courtesy of [Silverbolt](http://silverbolt.ai/) which I'm working for.\n","_attachments":{},"homepage":"https://github.com/danielgindi/rollup-plugin-natives","bugs":{"url":"https://github.com/danielgindi/rollup-plugin-natives/issues"},"license":"MIT"}