wp-calypso
wp-calypso copied to clipboard
Stats: Refactor "stats-redirect" folder
This is a follow-up of https://github.com/Automattic/wp-calypso/pull/95436.
Proposed Changes
- Remove the unnecessary
StatsRedirectFlow
component. - Rename the
stats-redirect
folder tostats-page-loader
. - Wrap Stats purchase page with
StatsPageLoader
to utilize purchase data.
Why are these changes being made?
- Remove the unnecessary redirecting component and rename the folder to correspond to its behavior.
Testing Instructions
- Spin this change up with the Calypso Live branch.
- Navigate to the Stats pages and ensure everything is not changed.
- Navigate to the Stats purchase page:
/stats/purchase/{site-slug}?productType=commercial
. - Ensure the purchasable tiers are based on the current tier.
Pre-merge Checklist
- [ ] Has the general commit checklist been followed? (PCYsg-hS-p2)
- [ ] Have you written new tests for your changes?
- [ ] Have you tested the feature in Simple (P9HQHe-k8-p2), Atomic (P9HQHe-jW-p2), and self-hosted Jetpack sites (PCYsg-g6b-p2)?
- [ ] Have you checked for TypeScript, React or other console errors?
- [ ] Have you used memoizing on expensive computations? More info in Memoizing with create-selector and Using memoizing selectors and Our Approach to Data
- [ ] Have we added the "[Status] String Freeze" label as soon as any new strings were ready for translation (p4TIVU-5Jq-p2)?
- [ ] For changes affecting Jetpack: Have we added the "[Status] Needs Privacy Updates" label if this pull request changes what data or activity we track or use (p4TIVU-aUh-p2)?