F12 Profiler dislike including /assets/js/block.min.js

Wordpress plugin F12 Profiler subsection /wp-admin/admin.php?page=f12-profiler#/plugins

shows:

searching for block.min.js finds only one occurrence, in wp-content/plugins/hivepress/includes/components/class-editor.php :

                // Register block script.
                wp_register_script( $args['script'], hivepress()->get_url() . '/assets/js/block.min.js', [ 'wp-blocks', 'wp-element', 'wp-components', 'wp-editor' ], hivepress()->get_version(), true );
                wp_add_inline_script( $args['script'], 'var hivepressBlock = ' . wp_json_encode( $args ) . ';', 'before' );

Is there anything that can be done to fix this?

Hi,

You can safely ignore this warning.

The block.min.js file is only used within the WordPress editor to register Gutenberg blocks. It is a very small file and is not loaded on the frontend of your website.

Because of this, it does not affect your visitors, page load times, SEO, Core Web Vitals, or frontend performance in any way. The warning is essentially a false positive in this context.

For additional context, we currently include this file for block registration purposes. However, we are already planning to migrate to the newer WordPress APIs in future updates, which will allow us to remove this file altogether.

1 Like