RFC: Lighthouse Subpackage Proposal (report UI and tracehouse)
See original GitHub issueEDIT: Updated June 2020 with the elements of this that we no longer need styled with strikethrough.
Summary
Long-term goals:
- Ensure package-like parts of Lighthouse are easy to maintain, develop, and consume.
- Facilitate the improvement of report UI components to handle use cases outside of the core report and a more app-like experience remains embeddable.
Long-term Proposal:
- Structure files/folders in a psuedo-lerna
packages/*
style withcore
,cli
,report
,viewer
,tracehouse
,logger
to establish logical delineations between packages. - Publish lighthouse-logger from
packages/logger
and publish tracehouse frompackages/tracehouse
, continue to publish the root aslighthouse
initially. - Eventually publish subpackages of
core
,cli
, andreport
. - Other package-like things (dependency graph, sd validation, manifest parser, etc) are first organized in a folder under
packages/core/lib
before being promoted to a folder inpackages/
if demand exists.
Short-term goals:
Share report UI elements with lighthouse-ci MVP.- Regularly publish tracehouse as its own package.
Short-term Proposal:
Break apart the monolithictemplates.html
andreport-styles.css
into reusable web components that could berequire
’d in lighthouse-ci.Augment those web components to support diff-modes where applicable.- Do the file/folder restructuring above and publish a minimal API from
packages/tracehouse
.
Short-term Hackier Alternatives:
Fork just the necessary report UI components in the lighthouse-ci repo, copy/paste certain styles for consistency.- Publish tracehouse straight from
lighthouse-core/lib/tracehouse
. It’s dependencyless and I mean how frequently do we update that logic anyhow.
To be honest, given our timeframe constraints and lack of clarity on where the report UI components might go, I think I prefer the hackier alternatives, but the long-term vision of doing things the right way does get me all warm and fuzzy, so feedback welcome! 😃
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:16 (4 by maintainers)
Top Results From Across the Web
No results found
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ah yes @adrianaixba I’m slowly working on this for tracehouse ( #11034 #11253 ), I’ll update 😃
@patrickhulce is this proposal still pending? 👀