#bojack420

1 messages · Page 1 of 1 (latest)

agile kayakBOT
golden junco
#

Hi there, you mean to display a loader while it's being loaded?

heady dew
#

yeah

heady dew
#

legend thank you~

golden junco
#

Happy to help

heady dew
#

I seem to be having trouble to get it to work

#

const options = {
amount: parseInt(this.total * 100),
loader: 'always',
mode: 'payment',
currency: 'aud',
setup_future_usage: 'off_session',
};

  const elements = this.stripe.elements(options);
#

did i implement this correctly?

golden junco
#

What problem are you facing?

heady dew
#

its not loading the skeleton at all

golden junco
#

have you checked browser console? Any error there?

heady dew
#

nope no errors

#

besides some content security policy directives but that occured way before hand

golden junco
#

Is there a public URL that I can visit and see your integration?

heady dew
#

umm not currently, are you able to send a screenshot of what the skeleton is meant to look like?

golden junco
heady dew
#

yeah mine isnt showing that little loading animation

#

just confirming this seems to look correct?

        loader: 'always',
        amount: parseInt(this.total * 100),
        mode: 'payment',
        currency: 'aud',
        setup_future_usage: 'off_session',
       };

      const elements = this.stripe.elements(options);
      this.elements = elements

      const expressCheckoutOptions = {
        wallets: {
          applePay: 'always',
          googlePay: 'always',
        }
      };

      const expressCheckoutElement = elements.create("expressCheckout", expressCheckoutOptions);

      expressCheckoutElement.mount("#express-checkout-element");```
#

my html is just
<div id="express-checkout-element"></div>

It doesn't have any css attached to it either

golden junco
#

It should be setupFutureUsage instead of setup_future_usage

heady dew
#

i've just updated that. seems to not have made a difference haha

golden junco
#

If you can upload your work somewhere public, I can take a look and help you troubleshoot

heady dew
#

yeah sure, ill chuck it up on ngrok

#

I've dm'd you the link

golden junco
#

The ExpressCheckout Element is displaying for me

heady dew
#

yeah but prior to loading it doesnt display anything

#

like a skeleton or anything

#

Display skeleton loader UI while waiting for Elements to be fully loaded doesnt seem to work

golden junco
#

Ah, the loader is only supported for for the Payment Element, the Link Authentication Element, and the Address Element.

#

It doesn't support ExpressCheckout Element yet

heady dew
#

ah ok yeah that makes sense

#

so i'll just need to add a custom loader for now im assuming

golden junco
#

Yup you can do that