Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to compile #954

Open
Chidan opened this issue Mar 6, 2019 · 4 comments
Open

Failed to compile #954

Chidan opened this issue Mar 6, 2019 · 4 comments

Comments

@Chidan
Copy link

Chidan commented Mar 6, 2019

Description

I am using version "element-react": "^1.4.33
As soon as Import any comoponent from element-react, I get the below error:

Failed to compile.

./node_modules/element-react/dist/npm/es5/libs/animate/index.js
Module not found: Can't resolve 'react-hot-loader' in 'C:\Chidu\Projects\amplifyagora\node_modules\element-react\dist\npm\es5\libs\animate'

Below is my simple code:


import React from "react";
import { Menu as Nav, Icon, Button } from "element-react";

const Navbar = () => <div>Navbar</div>;

export default Navbar;

@ghost
Copy link

ghost commented Mar 15, 2019

@Chidan I'm getting the same issue. I'm assuming you're doing the Reed Barger course? I downgraded to version 1.4.25 and it worked

@fodurrr
Copy link

fodurrr commented Mar 24, 2019

I had the same problem, downgrading as @edward-hong proposed solved the issue but would be nice if the latest element-react works with create-react-app as well.
Can somebody solve this?
Thanks

@prakashio
Copy link

@Chidan I'm also getting the same error when compiling and it's related to the react-hot-loader module.

Use this -

npm i -D react-hot-loader@next

@KandarpAjvalia
Copy link

@PRAKASH106 adding that as dev dependency fixed the issue, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants