Automattic\WooCommerce\Blocks

AssetsController::init()protectedWC 1.0

Initialize class features.

Method of the class: AssetsController{}

No Hooks.

Return

null. Nothing (null).

Usage

// protected - for code of main (parent) or child class
$result = $this->init();

AssetsController::init() code WC 9.0.1

protected function init() {
	add_action( 'init', array( $this, 'register_assets' ) );
	add_action( 'enqueue_block_editor_assets', array( $this, 'register_and_enqueue_site_editor_assets' ) );
	add_filter( 'wp_resource_hints', array( $this, 'add_resource_hints' ), 10, 2 );
	add_action( 'body_class', array( $this, 'add_theme_body_class' ), 1 );
	add_action( 'admin_body_class', array( $this, 'add_theme_body_class' ), 1 );
	add_action( 'admin_enqueue_scripts', array( $this, 'update_block_style_dependencies' ), 20 );
	add_action( 'wp_enqueue_scripts', array( $this, 'update_block_settings_dependencies' ), 100 );
	add_action( 'admin_enqueue_scripts', array( $this, 'update_block_settings_dependencies' ), 100 );
}