WEB_DEVELOPERSZZ Telegram 227
Top 7 useful JavaScript concepts that every developer should know

1. classList
It's a JavaScript property to work with classes in HTML, rather than using setAttribute to class it decreases code readability, in clssList, we have different properties like, a) add, b) remove, c) toggle d) contains and many more. classList is an easy an efficient way to work with classes for html elements.

2. insertAddacentHTML
This is JS DOM property, which is used to insert HTML in a HTML page via JavaScript, rather creating elements with .createEelement(), it makes the flow easy and efficient to work with creating HTML elements.

3. IIFE - Immediately invoked function expression
As the name suggests, IIFE functions are invoked (called) immediately as soon as they are defined. These functions are helpful when you want to invoke a function without any condition. IIFE function follows Block-scope scoping, so variables declared in the function can not be used outside of the function.

4. Optional chaining [?.]
Optional chaining is a safe way to access properties of a nested object or call a function. If the object or called function is null or undefined, it will always return undefined instead of throwing an error.

5. Logical AND [&&]
It's boolean operator which returns true only if both conditions are true, else it will return false. This operator can also be used when you want to perform a operation, based on only if the condition is either true or false. It saves storage space and increases code readability.

6. Condtional (ternary) operator [?:]
This operator is used when you want to overcome the use of so many if-else statement in your code. It's followed by 3 operands:
(condition) ? true : false

7. Plus (+)
By adding as prefix for any string number will change the datatype to number

Join @Web_developerszz for more



tgoop.com/Web_developerszz/227
Create:
Last Update:

Top 7 useful JavaScript concepts that every developer should know

1. classList
It's a JavaScript property to work with classes in HTML, rather than using setAttribute to class it decreases code readability, in clssList, we have different properties like, a) add, b) remove, c) toggle d) contains and many more. classList is an easy an efficient way to work with classes for html elements.

2. insertAddacentHTML
This is JS DOM property, which is used to insert HTML in a HTML page via JavaScript, rather creating elements with .createEelement(), it makes the flow easy and efficient to work with creating HTML elements.

3. IIFE - Immediately invoked function expression
As the name suggests, IIFE functions are invoked (called) immediately as soon as they are defined. These functions are helpful when you want to invoke a function without any condition. IIFE function follows Block-scope scoping, so variables declared in the function can not be used outside of the function.

4. Optional chaining [?.]
Optional chaining is a safe way to access properties of a nested object or call a function. If the object or called function is null or undefined, it will always return undefined instead of throwing an error.

5. Logical AND [&&]
It's boolean operator which returns true only if both conditions are true, else it will return false. This operator can also be used when you want to perform a operation, based on only if the condition is either true or false. It saves storage space and increases code readability.

6. Condtional (ternary) operator [?:]
This operator is used when you want to overcome the use of so many if-else statement in your code. It's followed by 3 operands:
(condition) ? true : false

7. Plus (+)
By adding as prefix for any string number will change the datatype to number

Join @Web_developerszz for more

BY Web Developer


Share with your friend now:
tgoop.com/Web_developerszz/227

View MORE
Open in Telegram


Telegram News

Date: |

Among the requests, the Brazilian electoral Court wanted to know if they could obtain data on the origins of malicious content posted on the platform. According to the TSE, this would enable the authorities to track false content and identify the user responsible for publishing it in the first place. A vandalised bank during the 2019 protest. File photo: May James/HKFP. A new window will come up. Enter your channel name and bio. (See the character limits above.) Click “Create.” Telegram channels enable users to broadcast messages to multiple users simultaneously. Like on social media, users need to subscribe to your channel to get access to your content published by one or more administrators. The channel also called on people to turn out for illegal assemblies and listed the things that participants should bring along with them, showing prior planning was in the works for riots. The messages also incited people to hurl toxic gas bombs at police and MTR stations, he added.
from us


Telegram Web Developer
FROM American