framer-motion-ticker
Version:
A React component that acts like a ticker, or marquee.
27 lines (23 loc) • 558 B
JavaScript
const BABEL_ENV = process.env.BABEL_ENV
const isCommonJS = BABEL_ENV !== undefined && BABEL_ENV === "cjs"
const isESM = BABEL_ENV !== undefined && BABEL_ENV === "esm"
module.exports = function (api) {
api.cache(true)
const presets = [
[
"@babel/env",
{
loose: true,
modules: isCommonJS ? "commonjs" : false,
targets: {
esmodules: isESM ? true : undefined,
},
},
],
"@babel/preset-typescript",
"@babel/preset-react",
]
return {
presets
}
}