Getting Started with Javascript

Saidur Rahman Riad
2 min readDec 8, 2021

Javascript is a scripting language that dynamically update content, control multimedia, animation and pretty much anything in the browser. It is currently the only language that is supported in browser.
To get started with writing Javascript on the web few steps are required. First let’s create a folder in a directory and open with Visual Studio Code. (If Visual Studio Code is not installed on your computer you can download it from here.

Open folder with Visual Studio Code

After opening the folder in VSCode, create two files, index.html, the starting point of our website (it’s common convention for name the file index.html to let the server know it’s the starting of our website) and main.js (it can be named anything depending on it’s requirement).

Next is to get started with some boilerplate html. Just type ! and hit tab on index.html and VSCode (emmet) will automatically write boilerplate for your html.

boilerplate html using VSCode (emmet)

Now at this point your webpage is ready . Now all we need to do is let the page know we are adding a Javascript file. Inside the body tag write:

<script src="./main.js"></script>

Save it, open it in Live Server and start writing Javascript.

your very first line in javascript

Happy Coding.

--

--

Saidur Rahman Riad

I am a self taught Software Developer with a CS degree.