Debugging Flashcards

Tools e resources of debbuging in Javascript

1
Q

How to print a value of your code in browser debug ?

A

Ex.:

let value = "variable";
 console.log(a);
//prints value
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Is it a good practice to enter console.log () in your code? justify your answer.

A

Missing answer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How to print value only once in Browser, independent of tests?

A

Console.clear();

Console.log(‘Some Value’);

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How to get data type of variable ?

A
let value = "Something";
typeof value
//results String
How well did you know this?
1
Not at all
2
3
4
5
Perfectly