2
3 Comments

React + Stripe v3 Subscription Implementation

Hey, I'm updating custom code to my product. FastDrop (FastDrop.io) . I'm having trouble updating my code with the new version of Stripe. I'm using React.js as my front end and Express and Node for my backend. I would appreciate any assistance with this matter.

on July 27, 2020
  1. 1

    Following for updates.

  2. 1

    Can you be more specific about the error or problem you are hitting? Uclusion is using React and code like

    stripe.createPaymentMethod(({
          type: 'card',
          card: elements.getElement(CardElement),
          billing_details: billingDetails
        })).then((paymentResult) =>{
          // console.log('Payment method creation successful');
          return usedSubmit(paymentResult, resetForm);
        }).catch((e) => {
          setError(e.error || e.error_message);
          setProcessing(false);
        });
    
    1. 1

      It's not even an error, the code works fine. It just is not the current version of Stripe I was using. I'm wondering if there is a tutorial our here for putting Stripe Subscriptions. Like a detailed guided to implement this: https://stripe.com/docs/billing/subscriptions/fixed-price