Line Continuation Character

There is no line continuation character like there is in VBA (_).
A single statement can span multiple lines.
The end of the line doesn't mean much to JavaScript.

var 
x
=
1 + 2 +
3 + 4;

Strings

The line continuation character in JavaScript is the back slash.

var mystring = 'this is my ' + 
'string that spans ' +
'three lines';

can be written as this

var mystring = 'this is my \  
'string that spans \
'three lines';



© 2020 Better Solutions Limited. All Rights Reserved. © 2020 Better Solutions Limited TopPrevNext