jest-ts-auto-mock
jest-ts-auto-mock copied to clipboard
FEATURE REQUEST | Support for @swc/jest
Hello guys.
first, thanks for this wonderful tool.
are you planning to add support for @swc/jest?
https://swc.rs/docs/usage/jest
https://github.com/swc-project/jest
Hi @justLuiz ! Sorry for the late reply! I will have a look! I am a bit busy with family!
Hey! So swc is a rust based compiler. Our plugin act on the compiler that it is in Javascript. In order to have the same kind of feature you could check what babel can do because I read that swc supports babel plugins. If you want to just use typescript and non babel unfortunately it will not work.
hey @uittorio thanks for reply...
yes, swc supports plugins, I don't know if the use of plugins is the same as in babel, anyway.
https://github.com/Typescript-TDD/ts-auto-mock is the best place for this discussion?
Myself and @Pmyl are the best people to ask questions. Ts auto mock is a better place but I am afraid you may not get a better answer. The problem is that swc does not use the typescript compiler or ast. Ts auto mock needs typescript itself not just the syntax language. I have the feeling that we may have to create a plugin specifically for swc. Feel free to start something, I am more than happy to contribute, I just dont have the time
no problem, i'll dig deep to understand better, and try to start something. thanks again.
I would be happy to practice some Rust :) as long as the data available during compilation is comparable I'm sure it can be done