WP_Script_Modules::get_import_map(): array

In this article

This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.

Returns the import map array.

Return

array Array with an imports key mapping to an array of script module identifiers and their respective URLs, including the version query.

Source

private function get_import_map(): array {
	$imports = array();
	foreach ( $this->get_dependencies( array_keys( $this->get_marked_for_enqueue() ) ) as $id => $script_module ) {
		$imports[ $id ] = $this->get_src( $id );
	}
	return array( 'imports' => $imports );
}

Changelog

VersionDescription
6.5.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.