I'm using a NodeJs backend with ESM package enabled mode to use es6+ import modules system when I'm trying to access a file in my test, even if I use require in my test file because target file uses import/export, it throws this error:
SyntaxError: Cannot use import statement outside a module
I know, I can use babel to solve Jest problem, but due to my main project files (which are using ESM), is there any solution to config Jest with ESM?