bamlab / react-native-image-resizer

🗻 Resize local images with React Native
MIT License
1.6k stars 342 forks source link

Typo for createResizedImage #321

Closed Saikedo closed 2 years ago

Saikedo commented 2 years ago

It seems like the documentation says that we should use ImageResizer.createResizedImage but in version 3.0.0 it seems like there is a typo in createResizedImage and instead it says createdResizedImage (notice that it says created instead of create).

Saikedo commented 2 years ago

I am also getting TypeError: undefined is not an object (evaluating 'p.default.createdResizedImage') every time I try to use the library.

And on Android the same with a very similar message. Can this be related?

taboulot commented 2 years ago

Hey @Saikedo

Indeed, I did some mistakes during the turbo module migration & I apologize. I've already fixed the version number in the README. Can you help me & create a PR for the other typos?

raquelmsmith commented 2 years ago

I'm also seeing this error. Using both createResizedImage and createdResizedImage give me the error. Were you able to get it working?

And if I downgrade to 1.4.5 then I see the error: Unhandled promise rejection [TypeError: undefined is not a function (near '..._reactNative.NativeModules.ImageResizer.createResizedImage...')]

taboulot commented 2 years ago

@raquelmsmith & @Saikedo

Indeed I made a typo when I generated the method. The doc says createResizedImage but index export createdResizedImage => going to fix it.

For the error you have, can you :