I'm making an app with react native and spring boot for backend, what is the best way to save images? Is it fine to get compressed base64 string from image crop picker and save it in the database?
I test it and it works. I chose 10 MB image and when it saved after compressing, it becomes 182kb and i test the fetching speed and its fast. so is it fine to do that? If not, what should i do?
i know i should upload the image in a folder in the server and put the path in the database but then what ? In React Native you cant put path for image as variable like:
<Image source={require(x) } />
and x is the saved path in database, i know that the hole thing "require (/path/image name)"
must be a variable to work but if i put in the database it doesn't work because it will be saved as string but it must be jxe to work so what is the solution?