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

misc(viewer): load *.json if no *.lighthouse.report.json #5343

Merged
merged 2 commits into from
May 24, 2018

Conversation

paulirish
Copy link
Member

Right now if you have a gist it'll only consider files *.lighthouse.report.json
This is usually OK because when you 'save to gist' it uses this filename. but we can afford to be flexible here

@paulirish paulirish changed the title viewer: consider loading *.json files misc(viewer): consider loading *.json files May 24, 2018
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.

easy-peasy nice!

could probably pull out Object.keys(json.files) and get some line wrapping wins ;)

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

.find(filename => filename.endsWith(GithubApi.LH_JSON_EXT));
if (!filename) {
Copy link
Member

Choose a reason for hiding this comment

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

// Otherwise, fall back to first json file in gist or something to follow up to previous comment?

@brendankenny brendankenny changed the title misc(viewer): consider loading *.json files misc(viewer): load *.json file if no *.lighthouse.report.json May 24, 2018
@brendankenny brendankenny changed the title misc(viewer): load *.json file if no *.lighthouse.report.json misc(viewer): load *.json if no *.lighthouse.report.json May 24, 2018
@paulirish paulirish merged commit 520f9ac into master May 24, 2018
@brendankenny brendankenny deleted the viewerdotjson branch May 24, 2018 19:08
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.

None yet

3 participants