-
Notifications
You must be signed in to change notification settings - Fork 210
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
Adding a new feature flag and setting to control SPE #3988
base: develop
Are you sure you want to change the base?
Conversation
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.
@wjrosa thanks for adding this. The changes are mostly working except the saving part.
✅ SPE checkbox is displayed when the feature flag is enabled.
✅ SPE checkbox is hidden when the feature flag is disabled.
✅ SPE checkbox is disabled when legacy is enabled.
Fixes #3892
Changes proposed in this Pull Request:
This PR introduces a new feature flag (
_wcstripe_feature_spe
) to control the Single Payment Element availability. This flag controls the feature as a whole, and does not behave like an option.When the flag is enabled, and the legacy checkout experience is disabled, you should be able to toggle the "Single payment element" feature in settings. When the flag is disabled, the option is not displayed.
Testing instructions
add/spe-feature-flag
)_wcstripe_feature_spe
). You can do it by either hardcoding the return value ofis_spe_available
totrue
or by runningnpm run wp option update _wcstripe_feature_spe 'yes'
wp-admin/admin.php?page=wc-settings&tab=checkout§ion=stripe&panel=settings
)_wcstripe_feature_spe
feature flagChangelog entry
Changelog Entry Comment
Comment
Post merge