首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >找不到模块'hclust‘的声明文件

找不到模块'hclust‘的声明文件
EN

Stack Overflow用户
提问于 2021-02-18 20:08:31
回答 1查看 38关注 0票数 0

我的npm安装了this模块,它显示在我的package.json的依赖项中。当我执行import { clusterData } from 'hclust'时,VS代码告诉我Could not find a declaration file for module 'hclust'. '/Users/danielsteman/Desktop/dev/spotify_cluster_analysis/webapp/reactTensor/node_modules/hclust/index.js' implicitly has an 'any' type. Try npm i --save-dev @types/hclust if it exists or add a new declaration (.d.ts) file containing declare module 'hclust';ts(7016)。我也试图运行npm i --save-dev @types/hclust,但是我得到了一个404not found的错误。我不知道如何解决这个问题。

EN

回答 1

Stack Overflow用户

发布于 2021-03-01 04:29:36

由于@types/hclust不存在,您需要为hclust模块创建自己的.d.ts声明文件。

当您这样做时,您也可以选择将其提交给DefinitelyTyped,以便其他人可以从中受益。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/66259662

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档