【发布时间】:2020-01-29 05:31:34
【问题描述】:
我刚刚在我的 pacakge.json 中添加了"@google-cloud/logging-winston":"2.1.0",,当我编译时出现以下错误。我偶尔会在其他谷歌库中看到这一点,其根本原因很可能是在从 protobuf 定义自动生成的类型的堆栈中更深层次。
../node_modules/@google-cloud/logging/build/proto/logging.d.ts:1434:32 - error TS2304: Cannot find name 'Long'.
1434 line?: (number|Long|null);
~~~~
../node_modules/@google-cloud/logging/build/proto/logging.d.ts:1453:38 - error TS2304: Cannot find name 'Long'.
1453 public line: (number|Long);
~~~~
../node_modules/@google-cloud/logging/build/proto/logging.d.ts:1543:39 - error TS2304: Cannot find name 'Long'.
1543 requestSize?: (number|Long|null);
~~~~
../node_modules/@google-cloud/logging/build/proto/logging.d.ts:1549:40 - error TS2304: Cannot find name 'Long'.
1549 responseSize?: (number|Long|null);
~~~~
../node_modules/@google-cloud/logging/build/proto/logging.d.ts:1576:42 - error TS2304: Cannot find name 'Long'.
1576 cacheFillBytes?: (number|Long|null);
【问题讨论】:
标签: node.js typescript google-cloud-platform google-api