{"id":13605658,"url":"https://github.com/iamspark1e/unplugin-zip-pack","last_synced_at":"2025-08-28T16:50:41.360Z","repository":{"id":190571579,"uuid":"676994736","full_name":"iamspark1e/unplugin-zip-pack","owner":"iamspark1e","description":"Zip your build files with JSZip, filtered by your rules, powered by unplugin","archived":false,"fork":false,"pushed_at":"2025-02-06T02:42:57.000Z","size":360,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-02T06:52:18.366Z","etag":null,"topics":["rollup","unplugin","vite","webpack","zip-pack"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/iamspark1e.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-08-10T13:45:16.000Z","updated_at":"2025-02-06T02:42:58.000Z","dependencies_parsed_at":"2023-08-25T09:28:20.936Z","dependency_job_id":"bdf6f556-7052-43c6-9a6f-79799d5da198","html_url":"https://github.com/iamspark1e/unplugin-zip-pack","commit_stats":null,"previous_names":["iamspark1e/unplugin-zip-pack"],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/iamspark1e/unplugin-zip-pack","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamspark1e%2Funplugin-zip-pack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamspark1e%2Funplugin-zip-pack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamspark1e%2Funplugin-zip-pack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamspark1e%2Funplugin-zip-pack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iamspark1e","download_url":"https://codeload.github.com/iamspark1e/unplugin-zip-pack/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamspark1e%2Funplugin-zip-pack/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264167269,"owners_count":23567041,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["rollup","unplugin","vite","webpack","zip-pack"],"created_at":"2024-08-01T19:01:01.297Z","updated_at":"2025-07-08T00:10:58.383Z","avatar_url":"https://github.com/iamspark1e.png","language":"TypeScript","readme":"\u003ch1  align='center'\u003eunplugin-zip-pack\u003c/h1\u003e\n\n\u003cp align='center'\u003e\n  \u003c!-- \u003ca href=\"https://codecov.io/gh/iamspark1e/unplugin-zip-pack\" \u003e\u003cimg src=\"\"/\u003e\u003c/a\u003e --\u003e\n  \u003ca href=\"https://www.npmjs.com/package/unplugin-zip-pack\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/unplugin-zip-pack\" /\u003e\u003c/a\u003e\n  \u003ca href=\"https://www.npmjs.com/package/unplugin-zip-pack\"\u003e\u003cimg src=\"https://img.shields.io/npm/dm/unplugin-zip-pack\" /\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003c!--\u003cp align='center'\u003eEnglish | \u003ca href=\"./README.zh.md\"\u003e中文文档\u003c/a\u003e\u003c/p\u003e--\u003e\n\u003cbr /\u003e\n\u003cp align='center'\u003e\u003ci\u003eZip your build files with JSZip, powered by \u003ca href=\"https://github.com/unjs/unplugin\" target=\"_blank\"\u003eunplugin\u003c/a\u003e\u003c/i\u003e\u003c/p\u003e\n\u003cp align='center'\u003e\u003ci\u003e使用JSZip打包构建成果，由\u003ca href=\"https://github.com/unjs/unplugin\" target=\"_blank\"\u003eunplugin\u003c/a\u003e驱动\u003c/i\u003e\u003c/p\u003e\n\u003cbr /\u003e\n\n## Quick Start\n\n```bash\nnpm i unplugin-zip-pack@latest -D # Or yarn/pnpm as you like\n```\n\n## Configuration\n\n```typescript\nexport type Options = {\n  /**\n   * Input Dir\n   * @default `./dist`\n   */\n  in?: string;\n  /**\n   * Output file name (with path)\n   * @default `dist.zip`\n   */\n  out?: string;\n  filter?: FilterFunction;\n  /**\n   * Switcher of enable plugin\n   * @default true\n   */\n  enabled?: boolean;\n  /**\n   * Hook functions run pre/post compress. (if `enabled` is set to false, hooks won't run.)\n   */\n  hooks?: {\n    pre?: Promise;\n    post?: Promise;\n  }\n}\n```\n\n## Usage\n\n\u003cdetails\u003e\n\u003csummary\u003eVite\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// vite.config.ts\nimport ZipPack from 'unplugin-zip-pack/vite'\n\nexport default defineConfig({\n  plugins: [\n    ZipPack({ /* options */ }),\n  ],\n})\n```\n\n\u003cbr\u003e\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003eRollup\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// rollup.config.js\nimport ZipPack from 'unplugin-zip-pack/rollup'\n\nexport default {\n  plugins: [\n    ZipPack({ /* options */ }),\n  ],\n}\n```\n\n\u003cbr\u003e\u003c/details\u003e\n\n\n\u003cdetails\u003e\n\u003csummary\u003eWebpack\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// webpack.config.js\nmodule.exports = {\n  /* ... */\n  plugins: [\n    require('unplugin-zip-pack/webpack')({ /* options */ })\n  ]\n}\n```\n\n\u003cbr\u003e\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003eNuxt\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// nuxt.config.js\nexport default {\n  buildModules: [\n    ['unplugin-zip-pack/nuxt', { /* options */ }],\n  ],\n}\n```\n\n\u003e This module works for both Nuxt 2 and [Nuxt Vite](https://github.com/nuxt/vite)\n\n\u003cbr\u003e\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003eVue CLI\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// vue.config.js\nmodule.exports = {\n  configureWebpack: {\n    plugins: [\n      require('unplugin-zip-pack/webpack')({ /* options */ }),\n    ],\n  },\n}\n```\n\n\u003cbr\u003e\u003c/details\u003e\n\n\u003cdetails\u003e\n\u003csummary\u003eesbuild\u003c/summary\u003e\u003cbr\u003e\n\n```ts\n// esbuild.config.js\nimport { build } from 'esbuild'\nimport ZipPack from 'unplugin-zip-pack/esbuild'\n\nbuild({\n  plugins: [ZipPack()],\n})\n```\n\n\u003cbr\u003e\u003c/details\u003e\n","funding_links":[],"categories":["Plugins"],"sub_categories":["Framework-agnostic Plugins"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiamspark1e%2Funplugin-zip-pack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiamspark1e%2Funplugin-zip-pack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiamspark1e%2Funplugin-zip-pack/lists"}