3.0: Configuration
In this module we'll have you configure a few things in Visual Studio Code so that you can optimize your build experience.
Open HTML files with Chrome
For the prework, it will be easiest for us to use Visual Studio Code(blue icon) for running HTML & CSS. We're going to install a package just for opening raw HTML.
Go to the extensions on the left side of VS Code.
Search for
open-in-browser
. The package looks like this:Install the package.
Go into
00-setup.html
in VS Code.DotNetProjects └── HTMLCSSPreWork └── 1-HTML-Basics └── 00-setup.html
Add the following snippet:
<html> <h1>Hello World</h1> </html>
Save your file by pressing
ctrl + s
.On a Windows machine, click on the
.html
file and pressctrl + alt + o
.You should be given a list of browsers. Choose Chrome.
You should see some text in a browser window:
Helpful Tip
Just a note on saving: VS Code has given us an easy to use tool for identifying unsaved files. The X which normally closes a tab will change to a solid circle or "bubble". It is very important that you adopt the habit of saving files before attempting to execute them.
Here is an unsaved file:
Here is a saved file:
Last updated