get( 'googlepay.button' ); /** * The Button. * * @var ButtonInterface $button */ $button->render_buttons(); } ); add_action( 'wp_enqueue_scripts', static function () use ( $c ) { $button = $c->get( 'googlepay.button' ); assert( $button instanceof ButtonInterface ); if ( $button->should_load_script() ) { $button->enqueue(); } } ); add_action( 'woocommerce_blocks_payment_method_type_registration', function( PaymentMethodRegistry $payment_method_registry ) use ( $c ): void { $payment_method_registry->register( $c->get( 'googlepay.blocks-payment-method' ) ); } ); } /** * Returns the key for the module. * * @return string|void */ public function getKey() { } }