Having trouble with Camera.getPhoto - appears to work, photo.path returns a full path, but trying to read the file with Filesystem results in a “File does not exist” error?
Using Capacitor with React, but not using the React hook, trying to use the Capacitor Camera and Filesystem APIs to take a photo, and copy the file to the app data.
I’m also running on an iPhone using:
ionic cap run ios -l --host=0.0.0.0
The following seems to work and generates what looks to be a valid URI, but no file exists at the URI.
const photo = await Camera.getPhoto({
quality: 90,
allowEditing: false,
source: CameraSource.Camera,
resultType: CameraResultType.Uri,
presentationStyle: 'popover'
// saveToGallery: true
});