如何在 Visual Studio Code 中将默认浏览器设置为 chrome? [英] How do I set the default browser as chrome in Visual Studio Code?

查看:284
本文介绍了如何在 Visual Studio Code 中将默认浏览器设置为 chrome?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是第一次设置我的 VS Code 环境,但我不知道如何将 Chrome 设置为工作区的默认浏览器.

I am setting up my VS Code environment for the first time, but I can't figure out how to set Chrome as the default browser for the workspace.

推荐答案

关于浏览器的其他 StackOverflow 问题与打开特定文件有关.以下是在全新环境中创建 tasks.json 文件的步骤.

The other StackOverflow questions regarding the browser, had to do with opening a specific file. Here are the steps to creating a tasks.json file in a brand new environment.

  1. 从任务"菜单中,选择配置任务"
  2. 输入字段会提示您选择要配置的任务"
  3. 选择从模板创建 tasks.json 文件"
  4. 编辑文件以包含以下块:

<小时>

{
            "version": "0.1.0",
            "command": "Chrome",
            "windows": {
                "command": "C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe"
            },
            "args": ["${file}"]
}

这篇关于如何在 Visual Studio Code 中将默认浏览器设置为 chrome?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆