首页 > 解决方案 > “找不到类型‘dart’的调试适配器。”

问题描述

在此处输入图像描述

我正在尝试在 vs 代码中调试飞镖脚本。

下面是我的launch.json -

    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        
        
        {
            "name": "todoapp",
            "request": "launch",
            "type": "dart"
        }
    ]
} ```

标签: jsonflutterdartvisual-studio-code

解决方案


转到扩展视图 (⇧⌘X) 并搜索Dart扩展。尝试卸载并重新安装 Dart 扩展,然后重新启动 VS 代码,看看它是否有效。

如果仍然无法正常工作,请安装旧版本的 Dart 并再次尝试。


推荐阅读