react-transition-group icon indicating copy to clipboard operation
react-transition-group copied to clipboard

Can't Resolve React-Transition-Group

Open JuliusGoddard opened this issue 2 years ago • 7 comments

When using Material-UI / React-Bootstrap or any other styles on React. The error "Can't resolve 'react-transition-group/Transition' in 'C:\Users\xxxxx\Documents\Web Development\bloglist-frontend\node_modules\react-bootstrap\esm'" comes up when trying to import any component.

How can this bug be worked around or fixed?

JuliusGoddard avatar Aug 03 '22 19:08 JuliusGoddard

What version of react-transition-group are you using?

koba04 avatar Aug 03 '22 23:08 koba04

I tried v2 (the most recent one) and when that didn't work I downgraded to v1 and that didn't work either.

JuliusGoddard avatar Aug 04 '22 15:08 JuliusGoddard

Could you create a repository or CodeSandbox project so that I can confirm the error?

koba04 avatar Aug 04 '22 16:08 koba04

In trying to run npm run build to create a repository... I got the same error again!: Can't resolve 'react-transition-group/Transition' in 'C:\Users\xxxxx\Documents\Web Development\bloglist-frontend\node_modules\react-bootstrap\esm'"

So I can't even create a repository for you because of this error.

JuliusGoddard avatar Aug 05 '22 09:08 JuliusGoddard

It took a long, long time to create this repository due to numerous errors along the way.

If you have the time, could you take a look and see if you could spot the problem?

https://github.com/JuliusGoddard/bloglist-frontend

JuliusGoddard avatar Aug 10 '22 12:08 JuliusGoddard

I am getting this error too. Currently My version is resolving with the declaration "^1.2.1".

I am using this as an example in my project

import React from "react";
import Bar from "./Bar";
import {CSSTransitionGroup} from "react-transition-group";

export default class Foo extends React.Component
{
    render = () => {
        return (
        <div>
            <CSSTransitionGroup
                  transitionName="example"
                  transitionEnterTimeout={500}
                  transitionLeaveTimeout={300}>
                  <Bar/>
        </CSSTransitionGroup>
        </div>
       );
    }
}

tylerlazenby avatar Aug 15 '22 21:08 tylerlazenby

@byuilazenbyt Try version ^2.0.1

pak11273 avatar Sep 13 '22 17:09 pak11273