Make WordPress Core

Changeset 52011


Ignore:
Timestamp:
11/04/2021 03:56:06 PM (2 years ago)
Author:
gziolo
Message:

Build: Remove polyfills from block view scripts

Related changes in Gutenberg: https://github.com/WordPress/gutenberg/pull/35038.

When adding a block with a view.js script, the frontend loads an additional ~20kb of scripts that were previously not there. These are coming from polyfills that are defined as a dependency for view.js scripts.
Since WordPress dropped support for IE, these polyfills are no longer needed and can be removed.

Follow-up to [51501].
See #53690.
Props aristath.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/blocks/file/view.asset.php

    r51501 r52011  
    1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => '499eaf2efb98327a07f222e92d742380');
     1<?php return array('dependencies' => array(), 'version' => '499eaf2efb98327a07f222e92d742380');
  • trunk/src/wp-includes/blocks/file/view.min.asset.php

    r51501 r52011  
    1 <?php return array('dependencies' => array('wp-polyfill'), 'version' => 'e8d668b8e69d9bf1c99dc250d92f2b72');
     1<?php return array('dependencies' => array(), 'version' => 'e8d668b8e69d9bf1c99dc250d92f2b72');
  • trunk/tools/webpack/blocks.js

    r51501 r52011  
    179179            } ),
    180180            new DependencyExtractionPlugin( {
    181                 injectPolyfill: true,
     181                injectPolyfill: false,
    182182            } ),
    183183            new CopyWebpackPlugin(
Note: See TracChangeset for help on using the changeset viewer.