Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Move embed scripts into the body in preview documents #10434
Jetpack supplies embeds that use shortcodes, and enqueue scripts needed for the embeds to work. We were including these scripts in
How has this been tested?
Install Jetpack and make sure the shortcode module is enabled.
Both should show a preview of the embed.
Types of changes
referenced this pull request
Oct 9, 2018
I hate to be that person, but is there any chance this could be something we have an E2E test for? I'm not sure how easy it'd be to test the embed appearing or the enabling of the Jetpack plugin without an account. I guess it might be a pain, but this seems a good candidate for something we could easily regress in the future.
Code makes sense to me though. If a test is too much of a pain, maybe you could add a comment about the reason the code is in the
body and not the
head? I could imagine someone in the future thinking they're clever and moving it back out!