# zip-img

> ## install

Latest version **1.0.3** (published 2023-04-26) · ISC license · 0 weekly downloads

## Install

```sh
npm install zip-img
pnpm add zip-img
yarn add zip-img
bun add zip-img
```

Provides the command `zip-img`.

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2023-04-26 |
| First published | 2023-04-26 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 5 |
| Unpacked size | 4.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | pianoboy |

## Links

- npm: https://www.npmjs.com/package/zip-img
- Repository: https://github.com/zhuqingyv/img-zip
- Homepage: https://github.com/zhuqingyv/img-zip#readme
- Issues: https://github.com/zhuqingyv/img-zip/issues
- npm.io page: https://npm.io/package/zip-img

## Dependencies (5)

- [cp-file](https://npm.io/package/cp-file.md) ^10.0.0
- [fs-extra](https://npm.io/package/fs-extra.md) ^11.1.1
- [gifsicle](https://npm.io/package/gifsicle.md) ^5.2.1
- [pngquant-bin](https://npm.io/package/pngquant-bin.md) ^6.0.1
- [compress-images](https://npm.io/package/compress-images.md) ^2.0.5

## Recent versions

- 1.0.3 (latest) — 2023-04-26
- 1.0.2 — 2023-04-26

## README

# zip-img

## install

``` shell
npm i zip-img -g
```

## Use
``` shell
zip-img projectName
```

## Config
Create a js named image-zip.config.js

``` javascript
export default {
  dir: {
    // your project'name you can run code 'zip-img projectName'
    projectName: {
      path: 'project1/*.{jpg,JPG,jpeg,JPEG,png,svg,gif}',
      option: {
        jpg: { engine: 'mozjpeg', command: ['-quality', '50'] },
        png: { engine: 'pngquant', command: ['--quality=80', '-o'] },
        svg: { engine: 'svgo', command: '--multipass' },
        gif: { engine: 'gifsicle', command: ['--colors', '80', '--use-col=web'] }
      }
    }
  },
  // some common options
  option: {
    jpg: {},
    png: {},
    svg: {},
    gif: {}
  }
};
```

---
_Source: https://npm.io/package/zip-img · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
