{"_id":"rollup-preserve-directives","_rev":"7-c7a566b1261ea9e6bf75f3ade589341a","name":"rollup-preserve-directives","dist-tags":{"latest":"1.1.3"},"versions":{"0.0.0":{"name":"rollup-preserve-directives","version":"0.0.0","keywords":[],"author":"","license":"ISC","_id":"rollup-preserve-directives@0.0.0","maintainers":[{"name":"sukkaw","email":"isukkaw@gmail.com"}],"dist":{"shasum":"9346eb55c9399ede0b575964be0975a64ac92c37","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-0.0.0.tgz","fileCount":1,"integrity":"sha512-S/ovHfM6zWL34uuP+lqS+nrevNmj9dE4NO6GqyuPGmWa9GUkOLDZLaAiEwgs4b9fPCJDSYRtNxXR05G0SeVSTg==","signatures":[{"sig":"MEQCIFqy4dWIIYxC9ro56Sqs2ozZZ87ZpVS2KSbCjcGSK9A2AiAVip+lIgD1y8VysbzCC/XQ1BU3lJbeCpU9AKeEBnNyog==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":240},"main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"sukkaw","email":"isukkaw@gmail.com"},"_npmVersion":"9.7.2","description":"","directories":{},"_nodeVersion":"18.16.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_0.0.0_1688880692039_0.333452945089308","host":"s3://npm-registry-packages"}},"1.0.0":{"name":"rollup-preserve-directives","version":"1.0.0","keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","_id":"rollup-preserve-directives@1.0.0","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"isukkaw@gmail.com"}],"dist":{"shasum":"6bd43b1380ce41daa6d9cf3af4f3442ac924401c","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.0.0.tgz","fileCount":7,"integrity":"sha512-9HVk/jWHQ8gQEvRGemMr6iSzKnflRWnbkYILpQ4Qbs0Xlcd09k4/GNnMlinPmkuBY6Hz3NtVtEf7sC4bNah2cQ==","signatures":[{"sig":"MEQCIA6hVOufiS0l53AOECW7KqbPvKly+ZPkWIPdMjkewJAsAiB2iX1n4wtDmsVeiX64c3CqUfF9VMzhYyo2u9w0jo4sCA==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":15933},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","module":"./dist/es/index.mjs","exports":{"types":"./dist/index.d.ts","import":"./dist/es/index.mjs","default":"./dist/cjs/index.js"},"gitHead":"c8069ab71ffb9e8eeb45c604e35a897e2de6fe4b","scripts":{"test":"jest --env node","build":"bunchee","test:update":"jest --env node --updateSnapshot","prepublishOnly":"rm -rf dist && pnpm run build"},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"_npmVersion":"9.6.7","description":"Rollup plugin to preserve directives","directories":{},"_nodeVersion":"18.17.1","dependencies":{"@napi-rs/magic-string":"^0.3.4"},"_hasShrinkwrap":false,"packageManager":"pnpm@7.24.3","devDependencies":{"jest":"^29.6.1","acorn":"^8.10.0","rollup":"^3.28.1","bunchee":"^3.6.1","rollup2":"npm:rollup@^2.79.1","rollup4":"npm:rollup@^4.4.1","@swc/core":"^1.3.96","@swc/jest":"^0.2.26","typescript":"^5.1.6","@types/jest":"^29.5.2","@types/node":"^20.4.1","@swc/helpers":"^0.5.1","@types/estree":"^1.0.1","rollup-plugin-swc3":"^0.9.0"},"peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_1.0.0_1701071875056_0.5078361207658615","host":"s3://npm-registry-packages"}},"1.0.1":{"name":"rollup-preserve-directives","version":"1.0.1","keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","_id":"rollup-preserve-directives@1.0.1","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"isukkaw@gmail.com"}],"dist":{"shasum":"98de12c3998abb33fe0afc20160d38ef4a339b49","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.0.1.tgz","fileCount":7,"integrity":"sha512-v7mFds6y7kBIaxWp0vipT2qeneRCRHO9YpUdYCv/7xmlvL+q+vwmCVdihkQYkO3JOBAa7zdBqkFAvdmTeOFY5w==","signatures":[{"sig":"MEYCIQCFsrZ2PXRkB46RMyGMEsgExC/Z/REMI4789k9txpkX+wIhANs4gT2RK1VkozsHq59tHDfObUhrWS3fZVPskvaYUTg6","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":16042},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","module":"./dist/es/index.mjs","exports":{"types":"./dist/index.d.ts","import":"./dist/es/index.mjs","default":"./dist/cjs/index.js"},"gitHead":"e7c6322ecc68b5b731a54d709bbe962dc18895b1","scripts":{"test":"jest --env node","build":"bunchee","test:update":"jest --env node --updateSnapshot","prepublishOnly":"rm -rf dist && pnpm run build"},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"_npmVersion":"9.6.7","description":"Rollup plugin to preserve directives","directories":{},"_nodeVersion":"18.17.1","dependencies":{"magic-string":"^0.30.5"},"_hasShrinkwrap":false,"packageManager":"pnpm@7.24.3","devDependencies":{"jest":"^29.6.1","acorn":"^8.10.0","rollup":"^3.28.1","bunchee":"^3.6.1","rollup2":"npm:rollup@^2.79.1","rollup4":"npm:rollup@^4.4.1","@swc/core":"^1.3.96","@swc/jest":"^0.2.26","typescript":"^5.1.6","@types/jest":"^29.5.2","@types/node":"^20.4.1","@swc/helpers":"^0.5.1","@types/estree":"^1.0.1","rollup-plugin-swc3":"^0.9.0","@rollup/plugin-commonjs":"^25.0.7"},"peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_1.0.1_1702076791423_0.2549732066835477","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"rollup-preserve-directives","version":"1.1.0","keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","_id":"rollup-preserve-directives@1.1.0","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"isukkaw@gmail.com"}],"dist":{"shasum":"4843d300945eaedb9030c182154b1e2213396dcc","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.1.0.tgz","fileCount":7,"integrity":"sha512-LL8yNGqtOrSL104TlTX12Ih5wgLHRFL/V2TY9DjGW0EKER5KQcLuYh3iL5T4L/YPP9TR4pvyh+imA+OetYNcyA==","signatures":[{"sig":"MEUCIHVAYhopByK3ZeeAGWqqXRsjOwE+j09nLl/0VbfQ/WrRAiEAicWYJj7vZhBxeFnOEBmNX2/RpSnC7HHkDB3z0cItdyE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":17149},"main":"./dist/cjs/index.js","types":"./dist/index.d.ts","module":"./dist/es/index.mjs","exports":{"types":"./dist/index.d.ts","import":"./dist/es/index.mjs","default":"./dist/cjs/index.js"},"gitHead":"7b03b86add2ddbec50a0c95b5a1088e1a6242533","scripts":{"test":"jest --env node","build":"bunchee","test:update":"jest --env node --updateSnapshot","prepublishOnly":"rm -rf dist && pnpm run build"},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"_npmVersion":"9.6.7","description":"Rollup plugin to preserve directives","directories":{},"_nodeVersion":"18.17.1","dependencies":{"magic-string":"^0.30.5"},"_hasShrinkwrap":false,"packageManager":"pnpm@7.24.3","devDependencies":{"jest":"^29.6.1","acorn":"^8.10.0","rollup":"^3.28.1","bunchee":"^3.6.1","rollup2":"npm:rollup@^2.79.1","rollup4":"npm:rollup@^4.4.1","@swc/core":"^1.3.96","@swc/jest":"^0.2.26","typescript":"^5.1.6","@types/jest":"^29.5.2","@types/node":"^20.4.1","@swc/helpers":"^0.5.1","@types/estree":"^1.0.1","rollup-plugin-swc3":"^0.9.0","@rollup/plugin-commonjs":"^25.0.7"},"peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_1.1.0_1702833431525_0.9156372439345963","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"rollup-preserve-directives","version":"1.1.1","keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","_id":"rollup-preserve-directives@1.1.1","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"isukkaw@gmail.com"}],"dist":{"shasum":"40d58b412ff791278ef06e0fa0944cbca3d6bd6d","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.1.1.tgz","fileCount":7,"integrity":"sha512-+eQafbuEfDPfxQ9hQPlwaROfin4yiVRxap8hnrvvvcSGoukv1tTiYpAW9mvm3uR8J+fe4xd8FdVd5rz9q7jZ+Q==","signatures":[{"sig":"MEQCICqMywe78mYZ8CB8nJwfhaHVlA7F/Al6KfPAeND2z1/sAiBEdEpXtDwBGAgaYQaqFR/I4IPaiOxnq9jxBWyYbjACig==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":18399},"main":"./dist/cjs/index.js","_from":"file:rollup-preserve-directives-1.1.1.tgz","types":"./dist/index.d.ts","module":"./dist/es/index.mjs","exports":{"types":"./dist/index.d.ts","import":"./dist/es/index.mjs","default":"./dist/cjs/index.js"},"scripts":{"test":"jest --env node","build":"bunchee","test:update":"jest --env node --updateSnapshot"},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"_resolved":"/private/var/folders/gy/kq4zjn8s0ljf9sfjyyh_nj640000gn/T/05cd9fdb0d90db2c3115964442dc616b/rollup-preserve-directives-1.1.1.tgz","_integrity":"sha512-+eQafbuEfDPfxQ9hQPlwaROfin4yiVRxap8hnrvvvcSGoukv1tTiYpAW9mvm3uR8J+fe4xd8FdVd5rz9q7jZ+Q==","_npmVersion":"9.6.7","description":"Rollup plugin to preserve directives","directories":{},"_nodeVersion":"18.17.1","dependencies":{"magic-string":"^0.30.5"},"_hasShrinkwrap":false,"packageManager":"pnpm@7.24.3","devDependencies":{"jest":"^29.6.1","acorn":"^8.10.0","rollup":"^3.28.1","bunchee":"^3.6.1","rollup2":"npm:rollup@^2.79.1","rollup4":"npm:rollup@^4.4.1","@swc/core":"^1.3.96","@swc/jest":"^0.2.26","typescript":"^5.1.6","@types/jest":"^29.5.2","@types/node":"^20.4.1","@swc/helpers":"^0.5.1","@types/estree":"^1.0.1","rollup-plugin-swc3":"^0.9.0","@rollup/plugin-commonjs":"^25.0.7"},"peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_1.1.1_1703778352155_0.5901884533356778","host":"s3://npm-registry-packages"}},"1.1.2":{"name":"rollup-preserve-directives","version":"1.1.2","keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","_id":"rollup-preserve-directives@1.1.2","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"npm@skk.moe"}],"homepage":"https://github.com/huozhi/rollup-preserve-directives#readme","bugs":{"url":"https://github.com/huozhi/rollup-preserve-directives/issues"},"dist":{"shasum":"c6954aba9f767988c681e00d41a46af521ce764f","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.1.2.tgz","fileCount":6,"integrity":"sha512-OOaYh4zO0Dcd/eVWGB8H69CgTiohl+jJqc2TLtjLENVIQaV2rxO3OW6RILzCQOdDvPT+/rzwRp+97OXhem895Q==","signatures":[{"sig":"MEUCIQCJqtReTGMmum8R+S5p+AF1/GtcMt7cKc4FuK5SCM9PKAIgRcOY09U/PEKCCglrMSDYAPS1hXYYIhFM91XVzRlIS1g=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":19003},"main":"./dist/cjs/index.js","types":"./dist/cjs/index.d.ts","module":"./dist/es/index.mjs","exports":{"import":{"types":"./dist/es/index.d.mts","default":"./dist/es/index.mjs"},"default":"./dist/cjs/index.js"},"gitHead":"5919742373d052908e670cbf739c799df241f158","scripts":{"test":"jest --env node","build":"bunchee","test:update":"jest --env node --updateSnapshot","prepublishOnly":"rm -rf dist && pnpm run build"},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"repository":{"url":"git+https://github.com/huozhi/rollup-preserve-directives.git","type":"git"},"_npmVersion":"10.2.4","description":"Rollup plugin to preserve directives","directories":{},"_nodeVersion":"20.11.1","dependencies":{"magic-string":"^0.30.5"},"_hasShrinkwrap":false,"packageManager":"pnpm@8.7.1","devDependencies":{"jest":"^29.6.1","acorn":"^8.10.0","rollup":"^4.24.0","bunchee":"^5.5.0","rollup2":"npm:rollup@^2.79.1","rollup3":"npm:rollup@^3.28.1","@swc/core":"^1.7.26","@swc/jest":"^0.2.26","typescript":"^5.1.6","@types/jest":"^29.5.2","@types/node":"^20.4.1","@swc/helpers":"^0.5.1","@types/estree":"^1.0.1","rollup-plugin-swc3":"^0.11.0","@rollup/plugin-commonjs":"^25.0.7"},"peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"_npmOperationalInternal":{"tmp":"tmp/rollup-preserve-directives_1.1.2_1728136868522_0.4720930445567455","host":"s3://npm-registry-packages"}},"1.1.3":{"name":"rollup-preserve-directives","version":"1.1.3","description":"Rollup plugin to preserve directives","repository":{"type":"git","url":"git+https://github.com/huozhi/rollup-preserve-directives.git"},"types":"./dist/cjs/index.d.ts","main":"./dist/cjs/index.js","module":"./dist/es/index.mjs","exports":{"import":{"types":"./dist/es/index.d.mts","default":"./dist/es/index.mjs"},"default":"./dist/cjs/index.js"},"scripts":{"build":"bunchee","prepublishOnly":"rm -rf dist && pnpm run build","test":"jest --env node","test:update":"jest --env node --updateSnapshot"},"keywords":["rollup","plugin","preserve","directives"],"author":{"name":"huozhi"},"license":"MIT","peerDependencies":{"rollup":"^2.0.0 || ^3.0.0 || ^4.0.0"},"dependencies":{"magic-string":"^0.30.5"},"devDependencies":{"@rollup/plugin-commonjs":"^25.0.7","@swc/core":"^1.7.26","@swc/helpers":"^0.5.1","@swc/jest":"^0.2.26","@types/estree":"^1.0.1","@types/jest":"^29.5.2","@types/node":"^20.4.1","acorn":"^8.10.0","bunchee":"^5.5.0","jest":"^29.6.1","rollup":"^4.24.0","rollup-plugin-swc3":"^0.11.0","rollup2":"npm:rollup@^2.79.1","rollup3":"npm:rollup@^3.28.1","typescript":"^5.1.6"},"packageManager":"pnpm@8.7.1","_id":"rollup-preserve-directives@1.1.3","gitHead":"158242a4333e038430b23cb09f9545c8699e6646","bugs":{"url":"https://github.com/huozhi/rollup-preserve-directives/issues"},"homepage":"https://github.com/huozhi/rollup-preserve-directives#readme","_nodeVersion":"20.11.1","_npmVersion":"10.2.4","dist":{"integrity":"sha512-oXqxd6ZzkoQej8Qt0k+S/yvO2+S4CEVEVv2g85oL15o0cjAKTKEuo2MzyA8FcsBBXbtytBzBMFAbhvQg4YyPUQ==","shasum":"a217dac6809a1c06d3c075d97fceabbb0fdfc242","tarball":"https://registry.npmjs.org/rollup-preserve-directives/-/rollup-preserve-directives-1.1.3.tgz","fileCount":6,"unpackedSize":19217,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDDUKK0K+wrL4wETyMnKW6n8PA/fIUUAavkDXF8y0tYYAiEA4TTNcxByS1qM4TL1qAUNOQfOZrYTDfLXMhVcSmmIcgQ="}]},"_npmUser":{"name":"huozhi","email":"inbox@huozhi.im"},"directories":{},"maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"npm@skk.moe"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/rollup-preserve-directives_1.1.3_1732461123933_0.8407476146209008"},"_hasShrinkwrap":false}},"time":{"created":"2023-07-09T05:31:32.039Z","modified":"2024-11-24T15:12:04.314Z","0.0.0":"2023-07-09T05:31:32.204Z","1.0.0":"2023-11-27T07:57:55.249Z","1.0.1":"2023-12-08T23:06:31.621Z","1.1.0":"2023-12-17T17:17:11.767Z","1.1.1":"2023-12-28T15:45:52.357Z","1.1.2":"2024-10-05T14:01:08.699Z","1.1.3":"2024-11-24T15:12:04.112Z"},"bugs":{"url":"https://github.com/huozhi/rollup-preserve-directives/issues"},"author":{"name":"huozhi"},"license":"MIT","homepage":"https://github.com/huozhi/rollup-preserve-directives#readme","keywords":["rollup","plugin","preserve","directives"],"repository":{"type":"git","url":"git+https://github.com/huozhi/rollup-preserve-directives.git"},"description":"Rollup plugin to preserve directives","maintainers":[{"name":"huozhi","email":"inbox@huozhi.im"},{"name":"sukkaw","email":"npm@skk.moe"}],"readme":"# rollup-preserve-directives\n\nA rollup plugin helps preserving shebang and string directives in your code.\n\n## Install\n\n```bash\nnpm install rollup-preserve-directives\n```\n\n## Usage\n\n```js\nimport preserveDirectives from 'rollup-preserve-directives'\n\nexport default {\n  input: './src/index.js',\n  output: {\n    file: './dist/index.js',\n    format: 'cjs'\n  },\n  plugins: [\n    preserveDirectives()\n  ]\n}\n```\n\n### Inter-plugin-communication\n\nThis plugin exposes the result of its directives information of current file for other plugins to use. You can access it via `this.getModuleInfo` or the `moduleParsed` hook.\n\n```ts\n// `meta` property info\n{\n  preserveDirectives: {\n    directives: string[]\n    shebang: string\n  }\n}\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md"}