Skip to content
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

Use wp_add_inline_script for publicPath #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

joshuafredrickson
Copy link

This allows one the ability to filter script attributes via wp_inline_script_attributes, which is particularly important for implementing Content-Security-Policy.

Without the ability to filter scripts attributes, there is no way to allow this script to safely run when the CSP requires disabling unsafe-inline.

Reference: https://core.trac.wordpress.org/ticket/39941

This allows one to take advantage of filtering via `wp_inline_script_attributes`, which is particularly important for implementing CSP.
joshuafredrickson added a commit to joshuafredrickson/responsive-pics that referenced this pull request Dec 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant