Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
imagemin-simple
Advanced tools
Replace images with minified one and generate small base64 image.
Replace images with minified one and generate small base64 image.
$ npx imagemin-simple imagemin '**/*.{jpg,png,JPG,PNG,svg,gif}'
$ npx imagemin-simple base64 '**/*.{jpg,png,JPG,PNG}' --output-file base64.json
{
"test-content1/project1/images/ai-image.jpg": {
"imagePath": "test-content1/project1/images/ai-image.jpg",
"width": 1000,
"height": 449,
"format": "jpeg",
"base64": "data:image/jpeg;base64,/9j/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAANAB4DASIAAhEBAxEB/8QAGQAAAgMBAAAAAAAAAAAAAAAAAQYEBQcI/8QAJhAAAgEDAQcFAAAAAAAAAAAAAQIDAAQRBQYSExQxQVEhUpHB8P/EABUBAQEAAAAAAAAAAAAAAAAAAAQF/8QAGxEBAAICAwAAAAAAAAAAAAAAAQACAyESIjH/2gAMAwEAAhEDEQA/AOfo7aQIjvjhsxXI81ZPFHDDGzMDxBld3xQtMSo0AAXcQEP1J7/dSb6AchGSSRGhKgeg64pldSPc5ewaPcRW2qWdxMhliimSRo/cAwJFOW3OoW9/rIutMjaOFkwyFcFWJzj93pCsXIniYdVYH4rQNubjltH0iZYoTLcRJK7lBvElT4pGN0sn5zsAT//Z"
},
...
}
imagemin-simple -h
imagemin-simple <command>
Commands:
imagemin-simple imagemin The imagemin command.
imagemin-simple base64 Turn image into base64.
Options:
-v, --version Show version number [boolean]
-h, --help Show help [boolean]
For more information go to https://github.com/evenchange4/hsu-scripts
imagemin-simple imagemin -h
Usage: imagemin-simple imagemin <pattern> [options]
<pattern> Glob pattern to specify files.
Options:
--plugin The list of plugins to use.
[array] [default: ["jpegtran","pngquant","svgo","gifsicle"]]
-h, --help Show help [boolean]
[boolean]
Examples:
imagemin-simple imagemin '**/*.{jpg,png,JPG,PNG,svg,gif}'
imagemin-simple imagemin '**/*.png' --plugin pngquant
imagemin-simple base64 -h
Usage: imagemin-simple base64 <pattern> [options]
<pattern> Glob pattern to specify files.
Options:
--output-file The output json file. [string] [default: "./base64.json"]
--cwd Set current working directory. [string]
-h, --help Show help [boolean]
Examples:
imagemin-simple base64 '**/*.{jpg,png,JPG,PNG}'
imagemin-simple base64 '**/*.{jpg,png,JPG,PNG}' --output-file results.json
imagemin-simple base64 '**/*.png' --cwd './docs'
The current working directory.
process.cwd()
# Default
$ npm run test:base64
# Set custom cwd
$ npm run test:base64-cwd
NOTE: Please check mrmlnc/fast-glob#cwd for more detail.
$ yarn install --pure-lockfile
$ npm run test:base64
$ yarn run build
$ yarn run flow-coverage
$ yarn run test:watch
$ yarn run test:base64
$ yarn run test:base64-cwd
$ yarn run format
$ yarn run eslint
$ npm version patch
$ npm run changelog
git commit & push
FAQs
Replace images with minified one and generate small base64 image.
The npm package imagemin-simple receives a total of 17 weekly downloads. As such, imagemin-simple popularity was classified as not popular.
We found that imagemin-simple demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.