What regex flavor is Jest transformIgnorePatterns using?

Viewed 120

What is the right way to write a pattern to ignore multiple modules in transformIgnorePatterns?

I was using:

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

and it worked, but now I want to add to new libraries to the pattern @my-domain/example-services and @my-domain/example-ui-web

I used the pattern:

"transformIgnorePatterns": [
        "<rootDir>/node_modules/(?!lodash-es|@my-domain/example-services|@my-domain/example-ui-web/.*)"
    ],

but it did not work, it's not ignoring @my-domain/example-services nor @my-domain/example-ui-web.

What flavor of regex is transformIgnorePatterns using? What would be the right regex to make it work?

0 Answers
Related