Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Domains: Update GSuiteUpgrade to use useShoppingCart #48516

Closed
wants to merge 3 commits into from

Conversation

sirbrillig
Copy link
Member

@sirbrillig sirbrillig commented Dec 18, 2020

Changes proposed in this Pull Request

This updates GSuiteUpgrade to use useShoppingCart from @automattic/shopping-cart in place of CartData. This will help us eventually remove CartData (see #24019). This is similar to the upgrade to GSuiteNudge from #48438.

Depends on #48202 because otherwise the domain that was added by the domain search page will not have finished updating the cart by the time we hit the G Suite page, causing the G Suite submission to overwrite it (which will probably fail since it will be in a cart without a domain).

Testing instructions

  • Add a domain to your cart.
  • Verify that you see the G Suite upsell before you reach checkout.
  • Add a G Suite product to your cart from the upsell.
  • Verify that you arrive at checkout and that the cart contains both your domain and the G Suite product.

@matticbot
Copy link
Contributor

@sirbrillig sirbrillig self-assigned this Dec 18, 2020
@sirbrillig sirbrillig added [Feature] Checkout The checkout screen and process for purchases made on WordPress.com. [Feature Group] Emails & Domains Features related to email integrations and domain management. [Feature] Shopping Cart Anything related to the shopping cart in Calypso, like adding items to the cart, the mini-cart, etc. labels Dec 18, 2020
@matticbot
Copy link
Contributor

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

Sections (~95 bytes added 📈 [gzipped])

name     parsed_size           gzip_size
domains       +260 B  (+0.0%)      +95 B  (+0.0%)

Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

@sirbrillig
Copy link
Member Author

Because this is so tightly tied to the domain search page, I cherry-picked this PR into #48202 and I'll close this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Checkout The checkout screen and process for purchases made on WordPress.com. [Feature Group] Emails & Domains Features related to email integrations and domain management. [Feature] Shopping Cart Anything related to the shopping cart in Calypso, like adding items to the cart, the mini-cart, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants