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

Jest transforms CJS packages, nested in ESM packages #10674

Open
Antreesy opened this issue Oct 10, 2023 · 0 comments
Open

Jest transforms CJS packages, nested in ESM packages #10674

Antreesy opened this issue Oct 10, 2023 · 0 comments

Comments

@Antreesy
Copy link
Contributor

Antreesy commented Oct 10, 2023

`<rootDir>/node_modules/(?!(?:.*\\/node_modules\\/)?(?:${ignorePatterns.join('|')}))`,

	transformIgnorePatterns: [
		`<rootDir>/node_modules/(?!(?:.*\\/node_modules\\/)?(?:${ignorePatterns.join('|')}))`,
	],

This RegExp still has a false negative. Like
/node_modules/ESM_PACKAGE/node_modules/CJS_PACKAGE/index.js
will NOT be ignored because it is inside ESM, while it should be, it's CJS.

Originally posted by @ShGKme in #10626 (comment)

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

1 participant