-
Add "Lighthouse CI Generator" as Your Application Dependencies
- Edit Your Application
package.json
with Following Details:
"scripts": { "lhci:build": "npm explore lighthouseci-generator -- npm run build", "lhci:start": "npm explore lighthouseci-generator -- npm start" }, "devDependencies": { "lighthouseci-generator": "ssh://[email protected]:amiroous/lighthouseci-generator.git#master" }
- Edit Your Application
-
Install Your Application Dependencies
- Open Terminal in Your Application Root and Run
npm install
- If you have more build steps like docker setups, make sure you still follow your app build process
- Open Terminal in Your Application Root and Run
-
Generate LHCI Files
- In Terminal Run
npm run lhci:build
- Follow and Answers Questions to the End
- In Terminal Run
-
Run Performance Test Manually
- In Terminal Run
npm run lhci:start
- Once Done, Look for a Generated Report Link in Terminal Messages and Open it in Browser.
- In Terminal Run
- If you select
Dynamic App
as your application type, you'll be asked to enter a start server command which basically will setup a temporary server on the host machine and then runs the test.