-
Notifications
You must be signed in to change notification settings - Fork 320
Dealing with Stripe.js load failure #237
Comments
@pgib thanks for reporting and sorry for the slow response. We've definitely seen this problem with stripe.js getting blocked too. I like the idea of using an |
We've definitely been seeing that error in our app, and Stripe is the most likely culprit. That said, it kinda looks like this library has been abandoned, so I'm not sure this is going to get resolved. |
If you have updated to React 16 and can update your integration, switching to @stripe/react-stripe-js and If you cannot, I'd recommend looking at our loader's source, and perform similar operations depending on how you load stripe.js today:
|
Closing this as it's a relatively old issue and this project has migrated to React Stripe.js. If you believe this is still important, please re-open it there. |
Summary
We've had some cases where people's "security" software have blocked the request to
https://js.stripe.com/v3/
, and I'd like to be able to elegantly detect this.The component that's wrapped inside the
<StripeProvider>
ends up exceptioning out like so:I simulate this locally by adding the following line to my
/etc/hosts
file:Is there any way to handle this? We haven't updated to React 16 (hopefully soon), and I know it will be easier to display an error, but it seems like there should be some way to handle this just within the component.
The text was updated successfully, but these errors were encountered: