-
Notifications
You must be signed in to change notification settings - Fork 2k
A4A > Marketplace: Implement placeholder for term pricing for Hosting, Products & Cart #107867
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
base: trunk
Are you sure you want to change the base?
A4A > Marketplace: Implement placeholder for term pricing for Hosting, Products & Cart #107867
Conversation
Jetpack Cloud live (direct link)
Automattic for Agencies live (direct link)
|
|
Here is how your PR affects size of JS and CSS bundles shipped to the user's browser: Sections (~727 bytes added 📈 [gzipped]) DetailsSections 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. Generated by performance advisor bot at iscalypsofastyet.com. |
|
@yashwin, I tested it, and it works just fine. My main concern is that we are doing a lot of conditional rendering. Do you think we can just calculate the value (discount and actual cost) within |
| const isFree = actualCost === 0; | ||
|
|
||
| const renderPrice = () => { | ||
| if ( isTermPricingEnabled ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can see that we are doing conditional rendering with the prices based on the term selected. I wonder if we could just handle the calculation from getProductPricingInfo so we don't have to do conditional rendering here and other places. wdyt?
288500f to
21a9dbb
Compare
|
Thanks for the review, @jkguidaven! I have made the changes as per your suggestions. Could you please take another look? |
|
This PR modifies the release build for the following Calypso Apps: For info about this notification, see here: PCYsg-OT6-p2
To test WordPress.com changes, run |
Part of https://linear.app/a8c/issue/A4A-1926/marketplace-show-monthlyearly-pricing-for-hosting-and-products
Resolves https://linear.app/a8c/issue/A4A-1929/products-display-monthlyyearly-pricing-on-cards
Resolves https://linear.app/a8c/issue/A4A-1930/hosting-display-monthlyyearly-pricing-on-cards
Resolves https://linear.app/a8c/issue/A4A-1961/cart-display-monthlyyearly-pricing
Proposed Changes
This PR implements a placeholder for term pricing for Hosting, Products & Cart.
Why are these changes being made?
Testing Instructions
?flags=a4a-bd-checkout> Test all the scenarios mentioned below > Verify the UI looks as displayed below with a placeholder for yearly and monthly billing.Billing term: Monthly
Billing term: Yearly
Pre-merge Checklist