I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:function myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, which seems to be widely used widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:function myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, which seems to be widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:function myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, which seems to be widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:function myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, andwhich seems to be widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, and seems to be widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:function myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, which seems to be widely used by the JavaScript community.
I am going to mostly focus on style here.
You need to indent your code. According to JSLint, JavaScript should use 4-space indentation.
You need to use braces around all your
if
s,for
s, &c. According to JSLint, you should style your braces like this:myFunction() { if (condition) { // Do something... } while (condition) { // Do something... } }
As demonstrated in the example above, you should also use a space after your closing parenthesis
)
and your opening brace{
.The man who wrote JSLint has a list of good styles, and seems to be widely used by the JavaScript community.