` tag for the enqueued script.
* @param string $handle The script's registered handle.
* @param string $esc_src The script's pre-escaped registered src.
*
* @return string Filtered script tag.
*/
function gutenberg_change_script_tag( $tag, $handle, $esc_src ) {
if ( ! is_admin() ) {
return $tag;
}
$tag = str_replace(
sprintf( "", $esc_src ),
sprintf( "", esc_attr( $handle ), $esc_src ),
$tag
);
return $tag;
}
add_filter( 'script_loader_tag', 'gutenberg_change_script_tag', 1, 3 );
}