https://github.com/maclovin/khumbor
A new Thumbor client for Node JS
https://github.com/maclovin/khumbor
Last synced: about 1 year ago
JSON representation
A new Thumbor client for Node JS
- Host: GitHub
- URL: https://github.com/maclovin/khumbor
- Owner: maclovin
- License: mit
- Created: 2015-03-27T20:47:52.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2015-03-27T21:40:02.000Z (over 11 years ago)
- Last Synced: 2023-08-16T23:07:42.881Z (almost 3 years ago)
- Language: JavaScript
- Homepage:
- Size: 141 KB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Khumbor (Thumbor url builder)
### Khumbor is a new Thumbor client for Node JS
_(A improved version of [https://github.com/PolicyMic/thumbor](https://github.com/PolicyMic/thumbor))_
### Usage after clone or install
```
var Khumbor = require('khumbor');
var thumbor = new Khumbor('[key]', 'http://thumbor.localhost.dev:8888');
var img = 'http://upload.wikimedia.org/wikipedia/en/a/ab/King_of_the_Beach_(Wavves)_album_cover.jpg';
// 3 different sizes of the same image, with the same instance.
var thumborUrl = [
thumbor.setImagePath(img).fitIn(355, 355).halign('center').buildUrl(),
thumbor.setImagePath(img).fitIn(250).halign('center').buildUrl(),
thumbor.setImagePath(img).fitIn(160).filter('fill(white)').buildUrl()
];
```
### Improvements
* Now you can set blank values to "Resize" and "Fitin" (100x or x100).
* I decided to create a check on the filtersCalls push. In this way, we don't need to create another Thumbor instance to use the same filters with another image url.
_hail ⚕_