-
Notifications
You must be signed in to change notification settings - Fork 45
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
Enable AMP support for tag detection. #207
Conversation
@warrengm & @jonkeller - Appreciate any feedback here and also a check for the tags I am detecting to make sure they are right. I'll test against a few sites to see if the results make sense. |
This is ready for some additional review/feedback. |
Copying my initial July 8 review from chat to here, for posterity. No action required.
|
lighthouse-plugin-publisher-ads/utils/resource-classification.js
Outdated
Show resolved
Hide resolved
lighthouse-plugin-publisher-ads/utils/resource-classification.js
Outdated
Show resolved
Hide resolved
Updated based on feedback. I'm not sure if I have captured all of the places that need to check for AMP ads as well, so appreciate review there. Do you have a testbed or a way to reproduce the reporting for each test? it would be great to have a way to make sure each test is working correctly in AMP. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One small comment but otherwise LGTM. Thanks!
@warrengm & @jonkeller - this is ready for another review! |
@@ -203,7 +272,9 @@ function isAdScript(url) { | |||
* @return {boolean} | |||
*/ | |||
function isAdRequest(request) { | |||
return isAdSenseAdRequest(request) || isGptAdRequest(request); | |||
return isAdSenseAdRequest(request) || |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note: broke into multiple lines because I was getting a pre-commit linting error about the line being too long.
I was able to clean this up a bit further, removing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but please don't merge until Warren also says so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding support for AMP!
Thanks for the guidance, reviews and approval. Once someone merges this, do you know how long it would be (roughly) before it becomes available at https://developers.google.com/publisher-ads-audits? |
I was about to type out a long answer to this, but instead I found this
awesome visualization:
https://amp.dev/documentation/guides-and-tutorials/contribute/vendor-contributions/release-schedule/
…On Wed, Jul 22, 2020 at 6:12 PM Adam Silverstein ***@***.***> wrote:
Thanks for the guidance, reviews and approval. Once someone merges this,
do you know how long it would be (roughly) before it becomes available at
https://developers.google.com/publisher-ads-audits?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#207 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASXMB6TIP5M6BKTFTQ3PHDR45P45ANCNFSM4OVA3HBA>
.
|
Excellent, thanks for clarifying! |
Actually, my apologies, what I said about the release schedule was wrong.
That was for AMP itself, whereas your change would go in according to the
release schedule of this plugin, which is more ad-hoc. Sorry for the
confusion!
…On Thu, Jul 23, 2020 at 8:56 AM Adam Silverstein ***@***.***> wrote:
Excellent, thanks for clarifying!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#207 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASXMB45PKD4EELYGQXSEVLR5AXPPANCNFSM4OVA3HBA>
.
|
Fixes ##206.
isAMPTag
check that finds the requiredamp-ad-0.js
tag.isAMPTag
inisGptTag
(to avoid adding across codebase for calls toisGptTag
(I can change this if preferred).Fetch
ResourceType inisGptAdRequest
so AMP ads are matched.