Fix bug when maxHeight === minHeight && maxWidth === minWidth.
Additionally:
This project has been converted to TypeScript with a generated type definition file.
The main method imageFileResizer accepts an options object argument instead of multiple individual arguments.
It returns a Promise instead of using a callback.
This PR refactors the code as properly typed functions. The parameters are in a single options argument instead of multiple arguments. The TypeScript definition file is automatically generated.
Fixes #94
Additionally:
imageFileResizer
accepts an options object argument instead of multiple individual arguments.This PR refactors the code as properly typed functions. The parameters are in a single options argument instead of multiple arguments. The TypeScript definition file is automatically generated.
Also addresses #93 , #78 , #62, and #50.
The code in this PR has been published as @peacechen/react-image-file-resizer pending merge.