【发布时间】:2021-07-13 01:01:03
【问题描述】:
今天将我的 deno 版本更新到 1.9 后,我在运行测试或脚本时开始遇到以下问题:
TS2729 [ERROR]: Property 'boundary' is used before its initialization.
readonly dashBoundary = encoder.encode(`--${this.boundary}`);
~~~~~~~~
at https://deno.land/std@0.63.0/mime/multipart.ts:266:52
'boundary' is declared here.
constructor(reader: Deno.Reader, private boundary: string) {
~~~~~~~~~~~~~~~~~~~~~~~~
at https://deno.land/std@0.63.0/mime/multipart.ts:269:36
我检查了一下,我没有在我的代码中的任何地方使用 mime 存储库,而是其他一些存储库必须使用它。
我正在使用以下存储库:
- x/abc
- 标准/uuid
- 标准/fs
- 标准/路径
- std/fmt
- 标准/测试
我确保对 std 库的所有导入(std 版本 0.93.0)明确使用最新版本。
当我运行导入 std 库的文件(而不是运行整个应用程序)时,不会发生错误。
有人知道如何解决这个错误吗?
【问题讨论】:
标签: deno