0 points

JavaScript White Space


dashboard

Fri Apr 24 2020 10:48:29 GMT+0000 (UTC)

Posted by @Saycute #javascript #javascript #spaces #whitespaces

var person = "Hege";
var person="Hege";

A good practice is to put spaces around operators ( = + - * / ):

var x = y + z;
content_copy Copy

JavaScript ignores multiple spaces. You can add white space to your script to make it more readable. The above lines are equivalent.

https://www.w3schools.com/js/js_statements.asp