Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upDisplay "<1" when rounding down to 0 #11316
Comments
|
Great idea for the report to do this when value isn't truly 0 9/10 though I would say it's a bug in the audit that it's trying to surface something that had 0 KiB :) |
|
does i18n complicate this? |
yeah i think we should be filtering out any items have have 0 in both columns. |
Looks like we can't be sure what format the number will be coming out of lighthouse/lighthouse-core/report/html/renderer/i18n.js Lines 42 to 50 in 7e2ce68 It's still possible to implement this if putting a "<" in front of a number makes sense for all languages, but I'm willing to bet that the "<1" format is not universal.
@paulirish Are you talking about items that display 0 or have an original value which is exactly 0? |
This came up in #11290:
The granularity is 1 so the transfer sizes of some payloads get rounded down to 0. In these cases I think it would be better to display something like "<1 KiB" to make it clear that Lighthouse didn't bug out and some small amount of data was fetched. I think this applies to pretty much any unit but are some units better displayed as is?