react-image-file-resizer icon indicating copy to clipboard operation
react-image-file-resizer copied to clipboard

**BREAKING CHANGE** OPTIONAL MAX WIDTH / HEIGHT

Open MattyPalka opened this issue 3 years ago • 2 comments
trafficstars

BREAKING CHANGE OPTIONAL MAX WIDTH / HEIGHT

  • Moved parameter position of maxWidth and MaxHeight
  • Allowed above parameters to be optional
    • if not provided result will be original size of image
  • changed vars to lets and consts

MattyPalka avatar Dec 23 '21 13:12 MattyPalka

  1. It'd be better to change it to requiring an options object with all the required and optional parameters in there. That would be the kind of breaking change that is much more future-proof.
  2. Changing to let/const should not be within the scope of such a change.

(I'm not the author btw, just another concerned user)

thany avatar Feb 22 '22 10:02 thany

@thany yeah I completely agree with you to have options object, but it was too many changes, so I just created my wrapper on top of this implementation :)

MattyPalka avatar Feb 22 '22 15:02 MattyPalka

Changing to let/const should not be within the scope of such a change.

Changing from var to const should always be in scope ;)

💯 on the options object. I couldn't believe the number of parameters!

donavon avatar Oct 29 '22 19:10 donavon