Automattic\WooCommerce\Blocks\BlockTypes
PaymentMethodIcons::enqueue_data
Extra data passed through from server to client for block.
Метод класса: PaymentMethodIcons{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->enqueue_data( $attributes );
- $attributes(массив)
- Any attributes that currently are available from the block.
По умолчанию:[]
Код PaymentMethodIcons::enqueue_data() PaymentMethodIcons::enqueue data WC 11.0.1
protected function enqueue_data( array $attributes = [] ) {
parent::enqueue_data( $attributes );
$this->asset_data_registry->add( 'availablePaymentMethods', $this->get_available_payment_methods() );
}