Features
Features Class.
Description Description
Source Source
File: packages/woocommerce-admin/src/Features/Features.php
Methods Methods
- __construct — Constructor.
- add_admin_body_classes — Adds body classes to the main wp-admin wrapper, allowing us to better target elements in specific scenarios.
- add_features_section — Adds the Features section to the advanced tab of WooCommerce Settings
- add_features_settings — Adds the Features settings.
- disable — Disable a toggleable beta feature.
- enable — Enable a toggleable beta feature.
- exists — Returns if a specific wc-admin feature exists in the current environment.
- get_beta_feature_options — Gets the beta feature options as an associative array that can be toggled on or off.
- get_feature_class — Get the feature class as a string.
- get_features — Gets a build configured array of enabled WooCommerce Admin features/sections.
- get_instance — Get class instance.
- is_enabled — Check if a feature is enabled. Defaults to true for all features unless they are in beta.
- load_features — Class loader for enabled WooCommerce Admin features/sections.
- load_scripts — Loads the required scripts on the correct pages.
- maybe_disable_features — Disable features when opting out of tracking.
- maybe_load_beta_features_modal — Conditionally loads the beta features tracking modal.