Automattic\WooCommerce\Blocks\Templates

CheckoutTemplate::get_placeholder_page()protectedWC 1.0

Returns the page object assigned to this template/page.

Method of the class: CheckoutTemplate{}

No Hooks.

Return

\WP_Post|null. Post object or null.

Usage

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

CheckoutTemplate::get_placeholder_page() code WC 8.9.0

protected function get_placeholder_page() {
	$page_id = wc_get_page_id( 'checkout' );
	return $page_id ? get_post( $page_id ) : null;
}