Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zswang/fis-optimizer-tinify
https://github.com/zswang/fis-optimizer-tinify
fis tinify
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/zswang/fis-optimizer-tinify
- Owner: zswang
- License: mit
- Created: 2015-11-11T05:31:10.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-04-08T06:56:37.000Z (over 6 years ago)
- Last Synced: 2024-10-03T17:35:55.641Z (about 1 month ago)
- Topics: fis, tinify
- Language: JavaScript
- Size: 34.2 KB
- Stars: 11
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
fis-optimizer-tinify
=================[![NPM version](https://img.shields.io/npm/v/fis-optimizer-tinify.svg)](http://badge.fury.io/js/fis-optimizer-tinify)
## 背景
Web 应用,图片是最占带宽的静态资源!
TinyPNG 是一个不错的图片压缩工具,压缩率平均可达 30%。
## 功能点
* 本地缓存已经压缩过的图片,增量压缩不会浪费请求。
* 自己发现...## 配置示例
```js
fis.match(/\.(png)$/i, {
optimizer: fis.plugin('tinify', {
key: [
...
],
cacheDir: __dirname + '/.cache'
})
})
```fis 插件 - tinify 图片压缩
参考:https://tinypng.com/