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

core(lhr): rename perf-hint, perf-info, etc #5102

Merged
merged 7 commits into from
May 3, 2018
Merged

Conversation

paulirish
Copy link
Member

@paulirish paulirish commented May 3, 2018

breaking change to the config:

  • perf-metric => metrics
  • perf-hint => load-opportunities
  • perf-info => diagnostics

Updated report classnames, and renderer method names.

ref #5008

@paulirish paulirish removed the request for review from vinamratasingal-zz May 3, 2018 18:55
Copy link
Collaborator

@patrickhulce patrickhulce left a comment

Choose a reason for hiding this comment

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

mostly LGTM, just a few naming nits and potential unnecessary changes

infoAudits.forEach(item => infoAuditsEl.appendChild(this.renderAudit(item)));
infoAuditsEl.open = true;
element.appendChild(infoAuditsEl);
const diagAudits = category.audits
Copy link
Collaborator

Choose a reason for hiding this comment

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

does diagnosticAudits push this over line limits? diag is a bit more of a stretch IMO :)

hintAudits.forEach(item => hintAuditsEl.appendChild(this._renderPerfHintAudit(item, scale)));
hintAuditsEl.open = true;
element.appendChild(hintAuditsEl);
const oppsEl = this.renderAuditGroup(groups['load-opportunities'], {expandable: false});
Copy link
Collaborator

Choose a reason for hiding this comment

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

might as well go with groupEl at this point :)

@@ -1131,7 +1131,7 @@
{
"id": "first-meaningful-paint",
"weight": 5,
"group": "perf-metric",
Copy link
Collaborator

Choose a reason for hiding this comment

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

what uses this, does it really need to be updated?

Copy link
Member

@brendankenny brendankenny left a comment

Choose a reason for hiding this comment

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

LGTM

@paulirish paulirish mentioned this pull request May 3, 2018
82 tasks
const diagnosticAudits = category.audits
.filter(audit => audit.group === 'diagnostics' && audit.result.score < 1);
if (diagnosticAudits.length) {
const diagsEl = this.renderAuditGroup(groups['diagnostics'], {expandable: false});
Copy link
Collaborator

Choose a reason for hiding this comment

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

I meant groupEl here too :)

@@ -153,30 +154,30 @@ class PerformanceCategoryRenderer extends CategoryRenderer {
element.appendChild(metricAuditsEl);

// Opportunities
const hintAudits = category.audits
.filter(audit => audit.group === 'perf-hint' && audit.result.score < 1)
const oppAudits = category.audits
Copy link
Collaborator

Choose a reason for hiding this comment

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

does opportunityAudits not fit? :D

@paulirish paulirish merged commit 9eb7882 into master May 3, 2018
@paulirish paulirish deleted the perfhint-renames branch May 3, 2018 23:13
kdzwinel pushed a commit to kdzwinel/lighthouse that referenced this pull request Aug 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants