Javascript is a scripting language that is used to create interactive and dynamic websites.Interactive website means ,user can perform some actions on website for example:
Button click
Submit a form
Write comments
Live chat
Dynamic website means the website that changes its content or layout like:
Sliding effect
Ecommerce website
Quiz website and many more
To start with javascript you need to have a web browser and a code editor
Getting started with basic fundamentals of Javascript:
Declaring a variable using :
var : It is the oldest and the most common way to declare a variable.
let : It is the newer keyword which was introduced in ES6(EcmaScript 6).
const : It is used to declare variables, which are constant throughout and cannot be changed.
Scope in javascript:
Scope in javascript refers to the visibility of variables and functions within a program.
Global Scope:
It is the outermost scope in a javascript program.Variables and functions declared in the global scope are visible from anywhere in the program.
Function scope:
It is created when a function is declared.Variables and functions declared in a function's scope are only visible within that function.
Block scope:
It refers to the visibility of variables and functions within a block of code.Variables and functions declared within a block scope are only visible within that block.
Javascript is the most popular programming language. It is used in almost all popular webistes.Great thing about javascript is that we can find tons of frameworks and libraries that can reduce our time to create websites and mobile apps.
Will be continuing the same in the next blog till then "Happy Coding".
Top comments (0)