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

Implements amp-analytics variables, csi pings for page load metrics. #13015

Merged
merged 3 commits into from Jan 25, 2018

Conversation

gskrell
Copy link
Contributor

@gskrell gskrell commented Jan 24, 2018

Follow up to #11378. Implements amp-analytics variables for Make Body Visible, First Contentful Paint, and First Viewport Ready.

Copy link
Contributor

@jonkeller jonkeller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

// Store certain page visibility metrics to be exposed as analytics variables.
const storedVal = Math.round(opt_delta != null ? Math.max(opt_delta, 0)
: value - this.initTime_);
if (label == 'fcp') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would make this a switch as it'll be easier to read

@keithwrightbos keithwrightbos merged commit aa3dc09 into ampproject:master Jan 25, 2018
@rsimha
Copy link
Contributor

rsimha commented Jan 25, 2018

@keithwrightbos @gskrell This PR seems to have broken gulp lint on master. https://travis-ci.org/ampproject/amphtml/jobs/333422431#L1698

Perhaps the tests were not run recently enough?

@jonkeller
Copy link
Contributor

jonkeller commented Jan 25, 2018 via email

gzgogo pushed a commit to gzgogo/amphtml that referenced this pull request Jan 26, 2018
…mpproject#13015)

* Prototype of page load amp analytics variables.

* Lint fixes for page load metrics.

* Change if statements to switch statement.
RanAbram pushed a commit to RanAbram/amphtml that referenced this pull request Mar 12, 2018
…mpproject#13015)

* Prototype of page load amp analytics variables.

* Lint fixes for page load metrics.

* Change if statements to switch statement.
protonate pushed a commit to protonate/amphtml that referenced this pull request Mar 15, 2018
…mpproject#13015)

* Prototype of page load amp analytics variables.

* Lint fixes for page load metrics.

* Change if statements to switch statement.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants