#Claire Kong
1 messages · Page 1 of 1 (latest)
It seems to relate with strict mode in JS.
Hello! Can you provide more details? What line of code throws that error?
yes, I use ionic angular 7 framework which has strict mode in the setting. It doesn't work in IOS device. I got the upper error. But it works in Android device.
import { loadStripe } from '@earnest crater/stripe-js';
const stripe = await loadStripe("xxx");
stripe?.confirmAlipayPayment(
"xxxx",
{
"return_url": "https://stripe.com"
},
{
"handleActions": false
}
).then((result: any) => {
console.log(JSON.stringify(result))
if (result.error) {
// Inform the customer that there was an error.
}
}, (error: any) => {
}
);
This is my code
stripe?.confirmAlipayPayment throws that error. It can't send request
We don't officially support Ionic. You'll likely need to get help from the folks who made the Ionic library you're using.
It's ts code with stripe-js. not related with Ionic library.
So officially stripe-js doesn't support strict mode?
Can you provide more details? I'm still not clear which specific line is throwing the error.
const stripe = await loadStripe("xxx");
We do support TypeScript: https://github.com/stripe/stripe-js?tab=readme-ov-file#typescript-support