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

Ensure HTML is written to disk when outputMode=pretty. #846

Merged
merged 1 commit into from
Oct 28, 2016

Conversation

shakyShane
Copy link
Contributor

outputMode in this case is derived from the CLI options and ends up being a regular string.
Then it's being compared to an enum value, which in Typscript is a number by default.

This PR ensures that we compare string against string and correctly write the HTML output to disk.

Note: there are cleaner ways to deal with enums in TS which I'd be happy to help with, but for now this fixes the issue.

`outputMode` in this case is derived from the CLI options and ends up being a regular string.
Then it's being compared to an enum value, which in Typscript is a number by default.

This PR ensures that we compare string against string and correctly write the HTML output to disk.
@samccone
Copy link
Contributor

Note: there are cleaner ways to deal with enums in TS which I'd be happy to help with, but for now this fixes the issue.

Would love your input in this :)

@samccone
Copy link
Contributor

👍 thanks for this

@samccone samccone merged commit 95d4ba4 into GoogleChrome:master Oct 28, 2016
andrewrota pushed a commit to andrewrota/lighthouse that referenced this pull request Jan 13, 2017
)

`outputMode` in this case is derived from the CLI options and ends up being a regular string.
Then it's being compared to an enum value, which in Typscript is a number by default.

This PR ensures that we compare string against string and correctly write the HTML output to disk.
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.

2 participants