JavaScript level Up step 10 points
- Primitive Values is six types.
numbers, Boolean, String, Biglnt, symbol
2. object and function is not null . object and function are values. object and function result show browser inspect colsole.log(). then show object and function values.
3. javascript cheacking string and numbers and object ,
console.log(takeOf(4)); // number
console.log(takeOf(“rakibul”)); // string
console.log(takeOf(undefined)); // undefined
4. Javascript cheaking object and function rules
console.log(typeof({})); // object
console.log(typeof([])); // object
console.log(typeof(a => a+ 4)); // function
5. javaScript one line true false,
= object true ? false
6. JavaScript error handling try catch rules try {//code}
7. var all time data decaler , let all time change data values. const one time data data antry …before change data then santeyx error ,
8. Labelled Block Statement
LabelIdentifier: {
StatementList
}
Labelidentifier target is break.
9. Arrow function expressions exmaple : -
const name= [
‘rakibul’,
‘monika’,
‘banecha ’,
‘wasife’
];
console.log(name.map(name => name.length));
// expected output: Array [8, 6, 7, 9]
10. Spread syntax
function sum(a, b, c) {
return a+ b+ c;
}
const numbers = [1, 2, 3];
console.log(sum(…numbers));
// expected output: 6
console.log(sum.apply(null, numbers));
// expected output: