In this PR we added a new entrypoint for motion components that's compatible with React Server Components.
The issue with import * as x is you remove the ability to support Proxy or other dynamically-assigned objects so the pattern of supporting motion(Component) and motion.div breaks.
This PR deprecates motion(Component) in favour of motion.create(Component)
In this PR we added a new entrypoint for
motion
components that's compatible with React Server Components.The issue with
import * as x
is you remove the ability to supportProxy
or other dynamically-assigned objects so the pattern of supportingmotion(Component)
andmotion.div
breaks.This PR deprecates
motion(Component)
in favour ofmotion.create(Component)