`visualDiff` of `@web/test-runner-visual-regression` can't be imported
Since version 0.10.0 of @web/test-runner-visual-regression typescript complains when trying to import visualDiff like: import { visualDiff } from '@web/test-runner-visual-regression'; (suggested by docs).
We assume that the index.d.ts which newly contains .mjs extension (export * from './browser/commands.mjs';) causes the problem. If the extension is removed, it works again.
Dependency update PR on our side with failing typescript: PR: https://github.com/sbb-design-systems/lyne-components/pull/3069 Logs: https://github.com/sbb-design-systems/lyne-components/actions/runs/10811479138/job/29990965173?pr=3069
Is there any update or workaround for this?
I guess I can do a patch package...
My patch for future reference:
diff --git a/node_modules/@web/test-runner-visual-regression/index.d.ts b/node_modules/@web/test-runner-visual-regression/index.d.ts
index f540538..5198ffa 100644
--- a/node_modules/@web/test-runner-visual-regression/index.d.ts
+++ b/node_modules/@web/test-runner-visual-regression/index.d.ts
@@ -1,2 +1,2 @@
// this file is autogenerated with the generate-mjs-dts-entrypoints script
-export * from './browser/commands.mjs';
+export * from './browser/commands';
Is there any update or workaround for this?
I guess I can do a patch package...
My patch for future reference:
diff --git a/node_modules/@web/test-runner-visual-regression/index.d.ts b/node_modules/@web/test-runner-visual-regression/index.d.ts index f540538..5198ffa 100644 --- a/node_modules/@web/test-runner-visual-regression/index.d.ts +++ b/node_modules/@web/test-runner-visual-regression/index.d.ts @@ -1,2 +1,2 @@ // this file is autogenerated with the generate-mjs-dts-entrypoints script -export * from './browser/commands.mjs'; +export * from './browser/commands';
@melink14 Could you open a pull request that fixes it pls? I would but preferably you should as you contributed the change...
@paladox My policy is not to open pull requests unless there is acknowledgement from the maintainers. This repo has a large number of open PRs and so I think it's worth waiting for some kind of message that a PR will be looked at before sending it.
Bumping this issue again. Is the team open to a PR for this?
https://github.com/modernweb-dev/web/pull/2932 was merged, so I presume you could open a pr and ping one of the committers?
I've done https://github.com/modernweb-dev/web/pull/2963 which credits you for the fix.
@bashmish can you share the process of getting this issue resolved?