WordPress at a glance
function is not described

Automattic\WooCommerce\Admin\Features

OnboardingTasks::add_onboarding_product_import_notice_admin_script() public WC 1.0

Adds a notice to return to the task list when the product importeris done running.

{} It's a method of the class: OnboardingTasks{}

No Hooks.

Return

null. Nothing.

Usage

$OnboardingTasks = new OnboardingTasks();
$OnboardingTasks->add_onboarding_product_import_notice_admin_script( $hook );
$hook(string) (required)
Page hook.

Code of OnboardingTasks::add_onboarding_product_import_notice_admin_script() WC 5.3.0

<?php
public function add_onboarding_product_import_notice_admin_script( $hook ) {
	$step = isset( $_GET['step'] ) ? $_GET['step'] : ''; // phpcs:ignore csrf ok, sanitization ok.
	if ( 'product_page_product_importer' === $hook && 'done' === $step && 'product-import' === self::get_active_task() ) {
		delete_transient( self::ACTIVE_TASK_TRANSIENT );

		$script_assets_filename = Loader::get_script_asset_filename( 'wp-admin-scripts', 'onboarding-product-import-notice' );
		$script_assets          = require WC_ADMIN_ABSPATH . WC_ADMIN_DIST_JS_FOLDER . 'wp-admin-scripts/' . $script_assets_filename;

		wp_enqueue_script(
			'onboarding-product-import-notice',
			Loader::get_url( 'wp-admin-scripts/onboarding-product-import-notice', 'js' ),
			array_merge( array( WC_ADMIN_APP ), $script_assets ['dependencies'] ),
			WC_ADMIN_VERSION_NUMBER,
			true
		);
	}
}