Conversation
pages/content/amp-dev/documentation/guides-and-tutorials/learn/spec/release-schedule.md
Outdated
Show resolved
Hide resolved
| return versionMap; | ||
| }; | ||
|
|
||
| const isAmp = ($) => { |
There was a problem hiding this comment.
We also want to check if it imports .*\/v0.js
There was a problem hiding this comment.
In the amp-toolbox the "isAmp" implementation just checks for the amp attribute.
What is the purpose of this additional check?
Should it be added with "and" or with "or"?
If it is "or" I think it is a very weak check to see if a page looks like it should be AMP since the pattern could match scripts that are not AMP easily. I think it would be better to check for <style amp- and <script custom-element="amp-
If it should be "and" I don't really see the benefit of adding it. When a user hosts the amp runtime on his server and the name no longer matches he should get an error that the page is not considered valid AMP and not that the page is no AMP at all (while the rest of the page might literally scream "I am an AMP page" ;-)
dba1d13 to
cdc6c14
Compare
The linter api now first checks if the page is a declared AMP page and only if that is true the linter checks are executed.
This PR also has the imported release schedule updated, which I did not really want to include here, but should do no harm.