Explained why you may want to comment code out. (#21204)

* Explained why you may want to comment code out.

* Update index.md
This commit is contained in:
Eme-rald
2018-11-16 09:14:26 -08:00
committed by Paul Gamble
parent 21c28f9a6a
commit ceaa347264

View File

@ -53,7 +53,7 @@ function addTwoNumbers(num1, num2) {
}
console.log(addTwoNumbers(10,20)) // will print 30 in the console.
You can also prevent execution of Javascript code just commenting the code lines like this:
In some cases you may want to prevent code from running for debugging purposes. For example:
```javascript
function hello() {
/*console.log("Hello world!");*/