Reputation: 300
I need to save sounds which my rn app is using on a database. I'm not really familiar with databases, so I chose the most easiest variant as I'm thinking - firebase. So, is there a possibility to save an mp3 file on this db using react native? If not, what db supports this feature?
Upvotes: 0
Views: 403
Reputation: 1866
You better store the files inside a storage like Google storage for firebase or AWS simple storage or any other storage.
And store the url of the file inside your database.
Upvotes: 0
Reputation: 10166
What you usually do in such cases is to store the actual file on a cloud storage service, such as AWS S3, while in your actual database you save the path to that file.
When you need to retrieve the file, you load the path from the database and with that information you can download the file from the storage.
If you want to remain in the firebase eecosystem, you should take a look at the cloud storage service for Firebase: https://firebase.google.com/docs/storage
Upvotes: 1