haideralii / playwright-lighthouse-test

4 stars 1 forks source link

[question]: import the lighthouse config #2

Open stevez opened 11 months ago

stevez commented 11 months ago

can you explain this line, why it is ended with js?

import desktopConfig from 'lighthouse/lighthouse-core/config/desktop-config.js';

https://github.com/haideralii/playwright-lighthouse-test/blob/afb583a66e0854cc4d0fec7a76088f9357233609/tests/lighhouse-performance-test.spec.ts#L3

ArCiGo commented 3 months ago

I'm not the repo's owner, but I suspect it finishes with .js because of the JS/TS compiler (probably some of the npm packages are using ESNext).

On the other hand, that line can be moved to the helpers.ts file.