The basic syntax gives guide to follow the syntax to create the JavaScript code.
There are almost 4 stages of syntax in JavaScript.
Variables are used to store data in JavaScript. It allow to assign values to names and use those names later in the code.
See More on this Reference
When storing data to names that data must be categorized as primitive or non-primitive data types.
- Primitive Data Types:
- numbers
- strings
- booleans
- null
- undefined
- symbols
- Non-Primitive Data Types:
- Objects
- Arrays
See More on this Reference
It performs certain operation on those data either comparing or assigning. These are the operators used in JavaScript:
- Arithmetic
- Comparison
- Logical
- Assignment
- Ternary
See More on this Reference
It control the flow of the JavaScript code execution. These are the control flow statements followed in JavaScript:
- Conditional statements
- Loops
See More on this Reference