Questions tagged [react-native-fs]

208 questions
0
votes
1 answer

Process download file before save

import RNBackgroundDownloader from 'react-native-background-downloader'; let task = RNBackgroundDownloader.download({ id: 'file123', url: 'https://link-to-very.large/file.zip' destination:…
Rambler
  • 267
  • 1
  • 12
0
votes
1 answer

React native video make private downloads directly

import Video from 'react-native-video';
Rambler
  • 267
  • 1
  • 12
0
votes
1 answer

How to get real Directory Path on iOS in React Native

I want to download a file in React Native and save it in a Directory selected by the User (e.g. Downloads). Right now I'm using https://www.npmjs.com/package/react-native-document-picker to let the user pick a directory and…
DeepValue
  • 54
  • 4
0
votes
0 answers

How to list all files/ folders of sdcard/external storage using react-native-fs

my question is how can I show or aleast get all contents in sdcard r external storage (all files and all folders) in react native using react-native-fs library.
Sharjeel Baig
  • 31
  • 1
  • 4
0
votes
1 answer

Set Background to an Image for Save to gallery

I have a qr-code in my react-native project from react-native-qrcode-svg like this: (svg = c)} />; I want to save this QR to the gallery! I use this code for…
0
votes
2 answers

React Native download and open file - file is blank on Android

So, I am using react-native-fs to download files from a url and then open to view/share/print them with react-native-file-viewer. This works fine for iOS but on Android there is an issue. I assume the file is downloading correctly since when passing…
0
votes
1 answer

Upload Video URI from React-Native Picker to AWS S3 Server

I am trying to upload a video from my IOS device library to S3 using axios and a pre-signed url. I've determined the axios/s3 part is working great, but the issue is coming from the uri I receive from 'react-native-image-picker'. When I record a…
0
votes
1 answer

How to extract data from Promise returned in function call in array

I'm trying to convert nested array of images into base64 use RNFS and it is returning me a promise and response is in Promise,Can you help me how to just get string instead of Promise.Thanks here is the ss Here is my code const items =…
Zaid Qureshi
  • 611
  • 10
  • 19
0
votes
1 answer

TypeError: null is not an object error when importing 'react-native-fs'

The line that causes the error is this: const RNFS = require('react-native-fs') The error I get is: TypeError: null is not an object (evaluating 'RNFSManager.RNFSFileTypeRegular')
BuhtanDingDing
  • 75
  • 1
  • 10
0
votes
1 answer

How to convert PNG image to base64 - React Native

I have stored some PNG images inside my app folder. And now I want to convert that PNG images to base64. Image file path : app > assets > images > sample.png I have tried react-native-fs library and it gives me a warning like this Error: ENOENT: no…
Akila Devinda
  • 5,054
  • 3
  • 19
  • 35
0
votes
1 answer

Getting this error using ffmpeg concat in ReactNative "concat imposible to open"

Hy, I am trying to concat multyple video using ffmpeg concat, testing on samsung j76, android version 8.1.0 const textFile = await (await writeTextFileWithAllVideoFiles(filePaths)) const outputPath = Platform.OS === 'ios' ?…
Josip Bogdan
  • 578
  • 1
  • 5
  • 15
0
votes
2 answers

How to access files in IOS that are stored in Files.app using react-native-fs?

I'm looking for a way to access the Files.app directory mainly the "Downloads" directory but the directory marked as "On My iPhone" would work as well. The use case will be a user downloads a certificate outside of the app into Files.app and the app…
asnyder002
  • 125
  • 8
0
votes
1 answer

Unable to update local json file in React native app

My React Native app file structure looks like this: /assests /json example.json /components view.js I need to take input from the user in the view.js component and store it in the example.json file for future use. I tried using…
0
votes
2 answers

react-native-fs cannot access storage

i'm using react-native-fs package to save files to android storage. when i perform these two lines of code, it works await RNFS.readDir(RNFS.DocumentDirectoryPath); =====>/data/user/0/com.youtubedljs/files await…
0
votes
1 answer

How should I navigate to a JSON file in react-native?

So, I am using this: RNFS.writeFile('./work.json', JSON.stringify(workData)); And the ./work.json path is apparently not working, error: Error: ENOENT: no such file or directory, open './work.json' , tho it it works in require() statements, Any…