Package name 'jsm' does not correspond to the file path ''
时间: 2024-01-23 10:02:35 浏览: 242
Unfortunately, as an AI language model, I do not have enough context to understand the issue you are facing. Can you please provide more information about the error message you are receiving? It would be helpful to know what programming language or tool you are using, what you were trying to do when you encountered the error, and any other relevant details. With that information, I can provide you with a more accurate solution to your problem.
相关问题
Could not find a declaration file for module 'three/examples/jsm/controls/OrbitControls.js'. 'E:/testqzy/my-vue-app-master/node_modules/.pnpm/three@0.148.0/node_modules/three/examples/jsm/controls/OrbitControls.js' implicitly has an 'any' type. Try `npm i --save-dev @types/three` if it exists or add a new declaration (.d.ts) file containing `declare module 'three/examples/jsm/controls/OrbitControls.js';`
这看起来像一个 TypeScript 编译器的错误信息。这是因为你的代码中使用了一个名为 `OrbitControls.js` 的模块,但 TypeScript 编译器不知道该模块的类型声明。要解决这个问题,你可以尝试安装 `@types/three` 类型声明文件:
```
npm install --save-dev @types/three
```
如果安装成功,TypeScript 编译器应该能够找到 `OrbitControls` 模块的类型声明,并消除这个错误。如果安装失败,你可以手动创建一个名为 `OrbitControls.d.ts` 的文件,其中包含以下内容:
```
declare module 'three/examples/jsm/controls/OrbitControls.js';
```
这将告诉 TypeScript 编译器,`OrbitControls` 模块的类型声明可以在运行时找到,从而避免这个错误。
阅读全文