前端性能測試之lighthouse


記錄一款簡單好用的前端性能測試工具:https://github.com/GoogleChrome/lighthouse

這是一款基於chorme的測試工具,使用很簡單:

1 使用npm全局安裝

2 安裝好后在cmd里運行:

lighthouse http://localhost:3000 --view --emulated-form-factor desktop -throttling-method=provided

如果URL有參數需要用" "將url包裹,如:lighthouse "http://localhost:9090/rendition/eppublic/uiservices/open_document?doc_id=4452574&show_html_only=true&internal_use_only=true&productCode=MultiCompany" --view --emulated-form-factor desktop -throttling-method=provided

關於-throttling-method=provided可以看:https://developers.google.com/web/tools/lighthouse/v3/migration


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM