1.1.1 • Published 4 years ago

shimr v1.1.1

Weekly downloads
-
License
ISC
Repository
gitlab
Last release
4 years ago

shimr - SHarp IMages Recursively

Compresses images and converts them to Webp format. Scans directory recursively and reflects the structure in destination directory.

Uses sharp.

Installation

Locally:

npm i shimr

Globally:

npm i -g shimr

Usage

shimr -s sourcePath -d distinationPath

Options

OptionDescriptionDefault value
-sSource directory./src
-dDestination directory./dist
-nowebpSkip converting to Webp formatfalse

Example

Example structure:

└── src
    ├── img
    │   ├── big.jpg
    │   ├── more-sizes
    │   │   └── sample@2x.png
    │   └── subfolder
    │       └── deeper-level
    │           └── sample.jpg
    └── this-is-not-an-image.txt

Run shimr. Shimr will generate new folder called dist reflecting the source folder's structure`:

└──  dist
    └── img
        ├── big.jpg
        ├── big.webp
        ├── more-sizes
        │   ├── sample.png
        │   ├── sample.webp
        │   ├── sample@2x.png
        │   └── sample@2x.webp
        └── subfolder
            └── deeper-level
                ├── sample.jpg
                └── sample.webp
1.1.1

4 years ago

1.1.0

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago