I have the following .babelrc.js
in the root folder:
{
"plugins": [
"@babel/plugin-transform-flow-strip-types",
"@babel/plugin-transform-modules-commonjs",
"@babel/plugin-transform-async-to-generator",
"@babel/plugin-transform-strict-mode",
"@babel/plugin-transform-runtime"
],
"cache": "true"
}
but when it tries to run node ./packages/jest-cli/bin/jest.js
I see:
Caching was left unconfigured. Babel's plugins, presets, and .babelrc.js files can be configured for various types of caching, using the first param of their handler functions:
What am I missing?
Use new babel.config.js
https://new.babeljs.io/docs/en/next/babelconfigjs.html
module.exports = function(api) {
api.cache(true)
return {
plugins: [
"@babel/plugin-transform-flow-strip-types",
"@babel/plugin-transform-modules-commonjs",
"@babel/plugin-transform-async-to-generator",
"@babel/plugin-transform-strict-mode",
"@babel/plugin-transform-runtime"
]
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With