Automattic\WooCommerce\Blocks\Domain
Bootstrap::__construct()
Constructor
Method of the class: Bootstrap{}
Hooks from the method
Return
null
. Nothing (null).
Usage
$Bootstrap = new Bootstrap(); $Bootstrap->__construct( $container );
- $container(Container) (required)
- The Dependency Injection Container.
Bootstrap::__construct() Bootstrap:: construct code WC 9.7.1
public function __construct( Container $container ) { $this->container = $container; $this->package = $container->get( Package::class ); $this->migration = $container->get( Migration::class ); $this->init(); /** * Fires when the woocommerce blocks are loaded and ready to use. * * This hook is intended to be used as a safe event hook for when the plugin * has been loaded, and all dependency requirements have been met. * * To ensure blocks are initialized, you must use the `woocommerce_blocks_loaded` * hook instead of the `plugins_loaded` hook. This is because the functions * hooked into plugins_loaded on the same priority load in an inconsistent and unpredictable manner. * * @since 2.5.0 */ do_action( 'woocommerce_blocks_loaded' ); }