expo / stripe-expo

Use the Stripe HTTP API in Expo without the DOM, node, or native deps
MIT License
159 stars 23 forks source link

createToken() returns SyntaxError: Unexpected token o in JSON at position 1 #23

Open sbkl opened 6 years ago

sbkl commented 6 years ago

Hi,

I've been using this library for quite a while and never had an issue to create a credit card token with the method createToken(card). The card variable being an object following the documentation:

card: {
    cvc: "123",
    exp_month: "03",
    exp_year: "2021",
    number: "4000 0034 4000 0004"
}

Suddenly, I get the following error: SyntaxError: Unexpected token o in JSON at position 1

Is this a bug?

Thank you.

sbkl commented 6 years ago

Still can't make it work but switched to tipsi-stripe library. I leave this issue open in case this is a real bug for this library.