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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Object transformer for transform and moduleNameMapper configs #7135
Comments
Worth to mention, I need this feature for this transformer https://github.com/straw-hat-team/jest-config/blob/a8a02da278df3169273345546fb669beb405f6c2/transforms/fileTransform.js#L8-L22 I want to be able to specify if I am in React ecosystem or not so I could ignore that transform. |
Specifying a transform directly instead of pointing to a module |
@SimenB for my personal knowledge, what do you mean by this?
I don't understand the underline architecture and I would like to if you don't mind to point me to some documentation about it or elaborate a little bit more about it, please. |
Definitely, the workers are an issue right now. 馃槩 |
Hi, I just made a PR with a similar feature to what was discussed here: #7398 I was able to get the config to support transforms as functions, and added unit tests to show that it works. That said, I'm not sure what this issue with workers is, and whether I need to address anything related to that... ? |
This issue is stale because it has been open for 1 year with no activity. Remove stale label or comment or this will be closed in 14 days. |
This issue was closed because it has been stalled for 7 days with no activity. Please open a new issue if the issue is still relevant, linking to this one. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
馃殌 Feature Proposal
Allow specifying a JavaScript object that represents the transformer on
transform
andmoduleNameMapper
configuration.Motivation
I created a factory function that creates some Jest configurations. In the JavaScript section, I have something like this
Because the transforms are set up by specifying a file I lose the factory configuration when I call the function.
Example
An example of how this could be fixed:
Pitch
Adding features like this one give more flexibility and power to advanced configurations.
The text was updated successfully, but these errors were encountered: