diff --git a/README.md b/README.md index c4d04e8..8dca61e 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,23 @@ Using the same source images as above would output this: +### Dimensions + +By default the new image dimensions will be set to the width of the widest source image and the height of the tallest source image. You can manually specify your own dimensions in the options object: + +```js +mergeImages(['/body.png', '/eyes.png', '/mouth.png'], { + width: 128, + height: 128 +}) + .then(b64 => document.querySelector('img').src = b64); + // data:image/png;base64,iVBORw0KGgoAA... +``` + +Which will look like this: + + + ## License MIT © Luke Childs