-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Framework: Migrate/remove temporary compatibility script initialization #19178
Conversation
00eafe8
to
7049159
Compare
This was left sitting for a while, but I've rebased the branch. Most of the original changes have been impacted by other pull requests (notably #18981 and #20628, cc @noisysocks and @mcsf). I've updated the original comment accordingly. |
Size Change: 0 B Total Size: 857 kB ℹ️ View Unchanged
|
Just to confirm, I did another pass at the core implementation to ensure that all of the inline scripts being removed here are reflected in WordPress 5.3.0: |
This pull request seeks to...
Remove a persistence script initialization which was incorporated in core as part of WordPress 5.2.0Edit: This was removed separately as part of Deprecate '@wordpress/nux' package #18981.Migrate remaining compatibility scripts toEdit: This is now removed altogether in this branch. It was originally slated for removal once support reached WordPress 5.3.0+ minimum (see original commit 3aac816 and associated Trac tickets Trac#48310 and Trac#48076). Since version support was bumped in Plugin: Bump minimum WordPress version to 5.3 #20628 to 5.3.0, it can be assumed to be safely removed.compat.php
with notes relevant for future removal. This affects API fetch nonce middleware, media upload middleware.Implementation Notes:
(Edit: This section does not apply anymore per latest updates)
The rationale for this change is based on the assumption that
client-assets.php
should be used for the bootstrapping of scripts relevant for Gutenberg, notably:These scripts will always need to exist in the plugin.
Conversely, scripts and filtering which serve a temporary purpose should be isolated in a way that it can be easily removed in future versions as compatibility requirements change. Currently, these are maintained in the
lib/compat.php
file.Testing Instructions:
Verify there are no regressions in the behavior of the nonce middleware, media uploads.