1.0.7 • Published 3 years ago

firebase-storage-upload-img v1.0.7

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

How to use firebase-storage-upload-image library

IMPORTANT!! You must use this library with expo-image-picker for now.

This library returns array of the uploaded images download url's.

You can import like this.

import { uploadImgToFirebase } from 'firebase-storage-upload-img'

Example Usage

const [selectedImages, setSelectedImages] = useState()

let result = await ImagePicker.launchImageLibraryAsync({
            mediaTypes: ImagePicker.MediaTypeOptions.Images,
            allowsMultipleSelection: true,
            quality: 0.1
        });

        if (!result.cancelled) {
            setSelectedImages(result)
        }

Example Usage

uploadImgToFirebase(selectedImages) // object or array
            .then((res) => { // res = string array
                tmpData = { ...tmpData, 'images': res }
            })
            .catch((e)=>console.log(e))
1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago