Edit Page

#MotionConfig

Set configuration options for Framer Motion.

The MotionConfig component can be used to set configuration options for all child motion components. Currently, it only accepts one prop, transition.

import { motion, MotionConfig } from "framer-motion"

export const MyComponent = ({ isVisible }) => (
  <MotionConfig transition={{ duration: 1 }}>
    <motion.div
        initial={{ opacity: 0 }}
        animate={{ opacity: 1 }}
      />
  </MotionConfig>
)

#Props

#transition: Transition

Defines a new default transition for the entire tree.