Giter Site home page Giter Site logo

gello-world's Introduction

gello-world's People

Contributors

benawad avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

gello-world's Issues

Question: How to upload photo in React native using Axios ?

Hi, Nice Tutorial. I used cloudinary before in other meteor apps so was kinda familiar with that. Thanks for the Tutorial.

Now, I was following this to get things up and running in React native. I am using https://github.com/ivpusic/react-native-image-crop-picker to pick the image. Image picks up fine. gallery shows ok, I can console.log the result and i see data and uri of image and image updates but problem is I can't seem to upload it to cloudinary.

Here is my code for uploading the photo

  _onPhotoPress = () => {
    ImagePicker.openPicker({
      width: 300,
      height: 400,
      cropping: true,
      mediaType: 'photo'
    })
      .then(image => {
        this.setState({ pic: image.sourceURL, file: image })
        console.log(this.state)
        console.log(image)
        const formData = new FormData()
        formData.append('file', this.state.file)
        formData.append('upload_preset', 'XXXX')
        return axios.post(
          `https://api.cloudinary.com/v1_1/XXX`,
          formData
        )
      })
      .catch(err => {
        console.log(`${err}`)
      })
  }

And here is the image object.
screenshot 2017-09-13 09 22 55

This is the error :
screenshot 2017-09-13 13 27 15

Thanks in Advance. Creating a react native-cloudinary-GQL image upload tutorial would be nice.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.