forked from ampproject/amphtml
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Visual diff comments and cleanup (ampproject#21032)
* visual-diff comments, explanation, and minor cleanup * Make the viewport resizing more clear * Double the number of parallel tabs * Fixed typos
- Loading branch information
1 parent
7c7659d
commit 38e05e2
Showing
3 changed files
with
126 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
build-system/tasks/visual-diff/snippets/remove-amp-scripts.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
// This file is executed via Puppeteer's page.evaluate on a document to remove | ||
// all <script> tags that import AMP pages. This makes for cleaner diffs and | ||
// prevents "double-execution" of AMP scripts when enableJavaScript=true. | ||
|
||
document.head.querySelectorAll("script[src]") | ||
.forEach(node => node./*OK*/remove()); |
Oops, something went wrong.