
Introduction to JavaScript!!
What is JavaScript: It was created in 1995 by Brendan Eich in just 10 days. You can run JavaScript directly in your browser — no installation needed to get started JavaScript is used to create interactive and dynamic web pages. It is responsible for adding functionality to the website and allows use interaction with the website content. Where to Write JavaScript? You can write JavaScript in 3 ways: Inline JavaScript: <button onclick= "alert('Hello')" > Click Me </button> Internal JavaScript: < script > alert ( " Hello World " ); < /script > External JavaScript (Best Practice): <script src= "script.js" ></script> Basic JavaScript Concepts Variables: Variables are containers for storing data. In modern JavaScript, you declare them using let or const. 1. let — for values that change It should have a Block Scope and must be declared before use. Also, Variables declared with let cannot be redeclared in the same scope and can be reassigned. let score = 0 ; score = 10 ; // ✅ we can reassign l
Continue reading on Dev.to Tutorial
Opens in a new tab


