最新Three.js版本中缺少AnimationAction类型定义

时间:2019-12-21 09:59:44

标签: typescript three.js

我正在使用Python,Typescript,Three.js等开发3D实时网络应用程序。

我使用Three.js 0.93几个月了。最近,我将Three.js升级到0.111。 它具有自己的类型定义,因此,我从public object Clone() { using (MemoryStream stream = new MemoryStream()) { if (this.GetType().IsSerializable) { BinaryFormatter fmt = new BinaryFormatter(); fmt.Serialize(stream, this); stream.Position = 0; return fmt.Deserialize(stream); } return null; } } 中删除了@types/three依赖项。

在修复类型错误时,我发现较新的类型定义中缺少package.json。错误消息是:

THREE.AnimationAction

我这样手动修改了[myproj]/node_modules/three/src/Three"' has no exported member 'AnimationAction'.ts(2694) ,因此能够解决该错误:

Three.d.ts

还有另一种解决此问题的正确方法吗?是否存在Three.js的固定版本?

0 个答案:

没有答案
相关问题