Introduction

A text editor is by far the most used developer tool regardless of what type of developer you are. A good text editor can help you write better code with real-time code checking, syntax highlighting, and automatic formatting.

Lesson overview

This section contains a general overview of topics that you will learn in this lesson.

  • What code editors are.
  • Why code editors are so useful for development.
  • Installing Visual Studio Code (VSCode).

Why can’t I use Microsoft Word?

Rich text editors, such as Microsoft Word and LibreOffice Writer, are great for writing a paper, but the features that make them good at creating nicely formatted documents make them unsuitable for writing code. A document created with these rich text editors has more than just text embedded in the file. These files also contain information on how to display the text on the screen and data on how to display graphics embedded into the document. In contrast, plain text editors, such as VSCode and Sublime, don’t save any additional information. Saving only the text allows other programs, like Ruby’s interpreter, to read and execute the file as code.

Code editors

You can think of code editors as specialized web development tools. They are highly customizable and offer many features that will make your life easier. There is nothing worse than spending two hours trying to figure out why your program isn’t working, only to realize that you missed a closing bracket. Plugins, syntax highlighting, auto-closing of brackets and braces, and linting are just a few of the benefits of using a code editor. There are many text editors out there to choose from, but we suggest starting with Visual Studio Code.

Visual Studio Code, or just VSCode as it’s commonly referred to, is an excellent free code editor. It has outstanding add-on support and great Git integration. VSCode is the most popular code editor among Odin’s students and moderators, so support is easy to find in the community.

Which editor you use is generally a matter of preference, but for the purposes of this course, we are going to assume you’re using VSCode because it’s free, easy to use, and works pretty much the same on every operating system. Keep in mind that this means you will not be able to get help if you are using a different text editor other than VSCode for the curriculum.

As a reminder, if you’re using a virtual machine, you should install VSCode on your VM. You’re welcome to also install it on your host (i.e., your Windows main OS), but ensure you have this critical tool inside your VM.

Assignment

  1. Depending on the OS you are running, follow the appropriate VSCode installation guide below:

    Going forward, if you have any issues with VSCode or want to know more about certain features, check the VSCode docs. There will also be many keyboard shortcuts you can use within VSCode, some of which may be specific to your OS and you can look up when you need.

  2. Familiarizing yourself with VSCode will allow you to save time and become more productive. By watching this VSCode Tutorial for Beginners video, you’ll get an idea of all the features VSCode has to offer. Don’t worry about actually coding along, just watch for the way that VSCode is used throughout the video.
  3. Disable the Copilot AI code completion feature which is enabled by default in Visual Studio Code. Do this by clicking the little robot face in the bottom right of your VSCode window and unchecking the code completions box. To understand why The Odin Project thinks you should disable this feature please revisit the Motivation and Mindset lesson section A note on AI code generation.

Knowledge check

The following questions are an opportunity to reflect on key topics in this lesson. If you can’t answer a question, click on it to review the material, but keep in mind you are not expected to memorize or master this knowledge.

Support us!

The Odin Project is funded by the community. Join us in empowering learners around the globe by supporting The Odin Project!