We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi, is it possible to use aurora.js with react-native? I tried this method: https://medium.com/@aakashns/using-core-node-js-modules-in-react-native-apps-64acd4d07140 an managed to have aurora.js read an asset from file using AV.Asset.fromFile();. But when I try asset.decodeToBuffer(), I get the following error:
AV.Asset.fromFile();
asset.decodeToBuffer()
Failed to execute 'readAsArrayBuffer' on 'FileReader': parameter 1 is not of type 'Blob'.
The text was updated successfully, but these errors were encountered:
Hi, could you share how you resolved this?
Sorry, something went wrong.
Hi. It was a long time ago... If I'm not mistaking, I had to read a file into a buffer and create the asset from that buffer, like this:
import RNFS from 'react-native-fs'; import b64AB from 'base64-arraybuffer'; ... const file = await RNFS.readFile(path, 'base64'); const buffer = b64AB.decode(file); const asset = AV.Asset.fromBuffer(buffer);
No branches or pull requests
Hi, is it possible to use aurora.js with react-native?
I tried this method: https://medium.com/@aakashns/using-core-node-js-modules-in-react-native-apps-64acd4d07140 an managed to have aurora.js read an asset from file using
AV.Asset.fromFile();
.But when I try
asset.decodeToBuffer()
, I get the following error:The text was updated successfully, but these errors were encountered: