JavaScript is the most important language for web development. Let's see how you can start learning it
A THREADπ§΅
In this thread, we will cover some quick points so that you will be able make functional websites within 10 - 15 days.
However JavaScript is much more than this. But this thread will give you a quick overview
{ 2 / 18 }
First things first, whenever I'm up to learning new technology or language, I always start with a crash course. By doing so I get a quick overview of things in almost no time
{ 3 / 18 }
Here's a crash course of JavaScript by Freecodecamp.
Crash courses are just for quick look. Don't just stop learning after it. Keep exploring things by your own
{ 4 / 18 }
The interesting part about JavaScript is that you can start writing it directly in your browser.
So you can have a taste of it without editor. Let's see how
{ 5 / 18 }
- Open your browser
- Right click anywhere
- Inspect
- A window will come
- From the top navigation bar, go to console
Here you can write JavaScript code
{ 6 / 18 }
1οΈβ£ Start with JavaScript Variables
Variable are nothing but containers for storing data values. You will use them almost 100% in your JavaScript code.
There are three ways to declare a variable using var, let and const keyword
{ 7 / 18 }
2οΈβ£ Loops and conditional statements
Loops are nothing but piece of code that repeats itself on a particular situation whereas conditional statement is a piece of code that runs when particular conditions occurs
Loops:
{ 8 / 18 }
3οΈβ£ alert() and prompt() methods
An alert box is often used to popup some message whereas prompt is used for taking input from user.
A typical exampleπ
{ 9 / 18 }
4οΈβ£ Arrays and their methods
We can say array is nothing but the collection of data.
Check this video for a quick look
{ 10 / 18 }
You can keep my array methods cheat sheets with you. Mostly while writing JavaScript code, you'll definitely use Array and it's methods.
So it's good thing to learn in the beginning
{ 11 / 18 }
5οΈβ£ JavaScript - HTML DOM methods
You might know that JavaScript is for adding behaviour in your webpage. For that you need to catch the HTML element so that you can change things accordingly
HTML DOM methods are actions
HTML DOM properties are values that you can set
{12/ 18}
Using HTML DOM you can
- Catch element in JavaScript file
- Change whatever you want
- Add or delete element
{ 13 / 18 }
6οΈβ£ Events
You can handle various events using JavaScript. An event can be defined as something the browser does, or something a user does.
For example, click is a event that user does, whereas onload is a event when user enters the page
{ 14 / 18 }
An example of typical click event
The onclick attribute fires on a mouse click on the element.
{ 15 / 18 }
7οΈβ£ The addEventListener()
When using the addEventListener() method, the JavaScript is separated from the HTML markup, for better readability and allows you to add event listeners even when you do not control the HTML markup
{ 16 / 18 }
For example, consider the same example as above.
There are a lot of other events as well that you can tackle and play around. For ex. mouseover, mouseout, focus,load, etc..
Everything you need to know before starting with web development
π§΅π
Hey, thereπ
If you want to learn web development then this thread is for you. In this thread, I will try to give a basic overview of the things you need to do to get started.
And any other doubt you have in mind... So Let's go
{ 2 / 23 }
Web development is a vast field but mainly revolves around 3 different technologies.
HTML, CSS and JavaScript - You can learn these things with 100 Days let's see how....
Beginner's guide to the most widely used hooks of React
The useState and useEffect hook
A long threadπ§΅ππ»
Start with the useState hook
- You will use it almost 100% in your component. The useState hook is not so tough to understand but there is some hiddent concepts, Let's start ππ»
{ 2 / 27 }
Working with React hooks, first thing you need to do is to import the particular hook