【问题标题】:Denon installation failed in Deno v1.18.0Deno v1.18.0 中的天龙安装失败
【发布时间】:2022-02-07 04:50:56
【问题描述】:

我尝试安装 denon 来运行我的 deno 脚本

我从他们的docs 中使用了以下命令,

deno install -qAf --unstable https://deno.land/x/denon/denon.ts

命令失败了,

error: TS2345 [ERROR]: Argument of type '"any" | "access" | "create" | "modify" | "remove" | "other"' is not assignable to parameter of type 'FileAction'.
  Type '"other"' is not assignable to type 'FileAction'.
            this.#changes[path].push(kind);
                                     ~~~~
    at https://deno.land/x/denon@2.4.10/src/watcher.ts:150:38

附:如果这是预期的行为,denon 有什么替代方法吗?

【问题讨论】:

    标签: nodemon deno


    【解决方案1】:

    编辑:此问题已在denon v2.5.0中修复

    原答案:

    这是denon 中的known bug,官方修复程序将很快发布,但与此同时,您可以安装一个补丁来解决此问题,请参阅this comment on GitHub

    deno install -qAf --unstable https://raw.githubusercontent.com/nnmrts/denon/patch-4/denon.ts
    

    您还可以降级到引入错误之前发布的版本。

    【讨论】:

    • 谢谢!这有效
    猜你喜欢
    • 2014-05-01
    • 2019-03-14
    • 2020-10-15
    • 1970-01-01
    • 2015-10-21
    • 2021-05-09
    • 2013-02-24
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多