Closed
Description
I believe this issue will be fixed when React 15.4 is released as per facebook/react#7386 (comment)
I just want to check this is indeed the case and that there's no another issue causing this error that could be fixed in create-react-app.
How to reproduce:
npm install velocity-react
- Create a component that utilized
velocity-react
:
<div>
<VelocityTransitionGroup
enter={{ animation: { opacity: 1 }, duration: 200 }}
leave={{ animation: { opacity: 0 }, duration: 200 }}
runOnMount
>
<div />
</VelocityTransitionGroup>
</div>
- Write a Jest snapshot test that checks that this component renders correctly:
it('renders correctly', () => {
const tree = renderer.create(
<Component />
).toJSON();
expect(tree).toMatchSnapshot();
});
- Observe the error in the console
Invariant Violation: ReactCompositeComponent: injectEnvironment() can only be called once.
Metadata
Metadata
Assignees
Labels
No labels