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

Unclear model for installing/using a plugin alongside LH #9052

Open
paulirish opened this issue May 24, 2019 · 4 comments
Open

Unclear model for installing/using a plugin alongside LH #9052

paulirish opened this issue May 24, 2019 · 4 comments
Assignees

Comments

@paulirish
Copy link
Member

  • Publisher ads includes LH as a dependency, and you're expected to clone their repo and run their CLI: node index.js <url>
  • Treo's field perf has LH as a peer dep and you're expected to create a project and install field-perf as a dep, then do npx lighthouse https://url --plugins=lighthouse-plugin-field-performance

Both of these seem a little backward. Most CLI users are expected to have LH as a global install.

(The situation where we're fine (I think) is when LH is a devDep and people run a yarn lighthouse script... in that case plugins should install (as another devDep) and run just fine.)

But with a global install of Lighthouse... what about plugins... Do you also install them as a global module? If so, the current --plugins= CLI flag doesn't successfully resolve them. If we don't support plugins with a global LH, then we'll need to document it. (but that seems bad).

@paulirish paulirish changed the title Unclear model for installing using a plugin alongside LH Unclear model for installing/using a plugin alongside LH May 24, 2019
@denar90
Copy link
Contributor

denar90 commented May 24, 2019

What I can add here is - it works great if:

  • both LH and plugin installed globally
  • both of them installed locally

@connorjclark
Copy link
Collaborator

We should not allow mixing of global/local installs.

make a repo template for plugins thats new hotness

@paulirish
Copy link
Member Author

Remaining work: add documentation for plugin use as a user.

@paulirish paulirish reopened this Jan 28, 2020
@patrickhulce patrickhulce added P1.5 and removed P1 labels Feb 25, 2020
@brendankenny
Copy link
Member

#11696 made the globally installed lighthouse work well now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants