woocommerce / woocommerce-gateway-stripe

The official Stripe Payment Gateway for WooCommerce
https://wordpress.org/plugins/woocommerce-gateway-stripe/
234 stars 204 forks source link

Payment buttons massively impact page speed #1439

Open Mingendahl opened 3 years ago

Mingendahl commented 3 years ago

Describe the bug If you activate the payment buttons (Apple- / Google-Pay), additional 33 (!!) requests to Stripe get fired in order to just create the payment button. This results in massive degradation of speed metrics (GTMetrix drop from A->B, Pingdom drop A->C, Pagespeed drop 77->39 ) which results in bad user experience and lower ranking in search results. On our pages, activating the payment buttons results in a 133% increase in total requests per page load.

To Reproduce Steps to reproduce the behavior:

  1. Disable payment buttons
  2. go to tools.pingdom.com and probe the page, check number of requests with stripe URLs
  3. enable payment buttons
  4. redo step 2 --> some 33 additional requests can be counted

Expected behavior Payment button integration uses a reasonable amount of requests (less than 5, best 1) and thus has no negative impact on speed metrics.

Screenshots Without Payment Buttons Pingdom image

Gtmetrix image

Google Pagespeed Mobile image

With Payment Buttons (no other changes) Pingdom image image

Gtmetrix image

Google Pagespeed Mobile image

Environment (please complete the following information):

Additional context Add any other context about the problem here.

crazyserb commented 3 years ago

I can confirm this on my end as an issue as well, tested and confirmed with GTMetrix and Pingdom.