FeaturesUtil::get_features()public staticWC 1.0

Get all the existing WooCommerce features.

Returns an associative array where keys are unique feature ids and values are arrays with these keys:

  • name
  • description
  • is_experimental
  • is_enabled (if $include_enabled_info is passed as true)

Метод класса: FeaturesUtil{}

Хуков нет.


null. Ничего (null).


$result = FeaturesUtil::get_features( $include_experimental, $include_enabled_info ): array;
Include also experimental/work in progress features in the list.
По умолчанию: false
True to include the 'is_enabled' field in the returned features info.
По умолчанию: false

Код FeaturesUtil::get_features() WC 8.7.0

public static function get_features( bool $include_experimental = false, bool $include_enabled_info = false ): array {
	return wc_get_container()->get( FeaturesController::class )->get_features( $include_experimental, $include_enabled_info );