找不到模块:无法解析'heatmap-calendar-react'

时间:2021-09-22 19:43:54

I've created a component that worked fine in my local App, but I'm trying to get it work on npm and I am getting this error:

我已经创建了一个在我的本地应用程序中运行良好的组件,但我试图让它在npm上工作,我收到此错误:

./src/App.js
Module not found: Can't resolve 'heatmap-calendar-react' in 
'C:\Users\account\app\src'

Could somebody please take a look at my repository and help me understand what the issue may be?

有人可以看看我的存储库并帮助我了解问题所在吗?

https://github.com/willfretwell/heatmap-calendar-react

https://github.com/willfretwell/heatmap-calendar-react

Any help would be greatly appreciated.

任何帮助将不胜感激。

2 个解决方案

#1


0  

Add an index.js at the root, and have it import/export /src/index.jsx

在根目录下添加index.js,并将其导入/导出/src/index.jsx

#2


0  

Solved, I had a typo in the main declaration.

解决了,我在主要宣言中有一个错字。

#1


0  

Add an index.js at the root, and have it import/export /src/index.jsx

在根目录下添加index.js,并将其导入/导出/src/index.jsx

#2


0  

Solved, I had a typo in the main declaration.

解决了,我在主要宣言中有一个错字。