@obinnae wrote:
I’ve been experiencing this issue for days now. I’m trying to upload a photo to Firebase Storage using the following code in Ionic 3:
import * as firebase from 'firebase/app'; import 'firebase/storage'; /// *** blah blah blah try{ firebase.storage().ref(url).putString(base64image, 'base64', {contentType: 'image/jpg'}) .then((path)=>resolve(path.downloadURL)) .catch((e)=>{reject(e)}); }catch (error) { console.warn("What the heck? ", error); }
yet everytime I run it, I get the error
ERROR Error: Uncaught (in promise): TypeError: Object(...) is not a function TypeError: Object(...) is not a function at handler (vendor.js:152661)...
referring to the putString(…) function. Annoyingly, it doesn’t even get caught by the try/catch.
What’s wrong with this thing?? Please help! Thanks.
Posts: 1
Participants: 1