Skip to content

2. Setup Workspace

INSTALL PRE-REQUISITES

Ensure that the pre-requisites are installed before continuing.

TIP

It is highly recommended to develop in a Windows environment.

1. Create a Folder

Determine a location on your computer to store your server files.

This tutorial we'll just create a folder on the desktop.

2. Open the Folder and a Terminal in the Directory

Open the folder by double-clicking on it.

Then hold LEFT SHIFT and RIGHT-CLICK inside of it and open a PowerShell, Terminal, or any CLI instance inside of directory.

Run the Following Command in the Terminal

sh
npm init

This command creates package.json file inside of the folder.

Hold ENTER down to quickly fill in all information.

3. Open a VSCode Instance in the Folder

Open the folder with VSCode.

Run the Following Command in the Terminal

sh
code .

4. Quick Rundown of VSCode

VSCode is really easy to use.

  • File Tree is on the LEFT
  • File Contents show up on the RIGHT when you click on a file
  • Open Files show up in tabs ABOVE the File Contents

The next thing is to open a Terminal inside of VSCode. This is what makes VSCode really nice for development.

Open a Terminal in VSCode you can use this Key Bind: CTRL + ~

Open a Terminal by Terminal Menu Option -> New Terminal

You should see something like this in your VSCode

5. Update package.json

Click on package.json in your file tree, and add the following line somewhere in the JSON structure. Preferrably under main or description.

json
{
	...
	"type": "module",
	...
}

Like this...

Ignore the ... they're just telling you there should be content above / below our main focus

Documentation Created with ❤️ by Stuyk