What are you trying to achieve?
I am writing a webpack loader to optimize images, some of that work includes resizing. For dev purposes I need to know up-front what will be the image dimensions. As the user can specify the width only I need to infer the height. After looking at sharp source code I found these lines:
What are you trying to achieve?
I am writing a webpack loader to optimize images, some of that work includes resizing. For dev purposes I need to know up-front what will be the image dimensions. As the user can specify the width only I need to infer the height. After looking at sharp source code I found these lines: