Jest: `transformIgnorePatterns` is not work right, It spends to much time with typescript

Created on 22 May 2017  路  3Comments  路  Source: facebook/jest


Do you want to request a feature or report a bug?
bug

What is the current behavior?
I report an issue to ts-jest but no result.
I report it here
https://github.com/kulshekhar/ts-jest/issues/218

If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can yarn install and yarn test.

What is the expected behavior?

Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.

Most helpful comment

You use wrong regex. It should be:

"transformIgnorePatterns": [
  "<rootDir>/node_modules/(?!lodash-es/)"
],

All 3 comments

  • Issue

[describe the issue here]
transformIgnorePatterns is not work right, and it spends to much time.
For example:

"<rootDir>/node_modules/(?!lodash-es)/"

Expect not to scan node_modules exclude node_modules/lodash-es
This config is work right with js file, but spends to much time with ts file

You use wrong regex. It should be:

"transformIgnorePatterns": [
  "<rootDir>/node_modules/(?!lodash-es/)"
],

Thanks, sorry for this.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ticky picture ticky  路  3Comments

paularmstrong picture paularmstrong  路  3Comments

jardakotesovec picture jardakotesovec  路  3Comments

kgowru picture kgowru  路  3Comments

withinboredom picture withinboredom  路  3Comments