Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Commit 4874d38

Browse files
committed
Merge pull request #10 from mobify/fix-whitespace
Fix whitespace not conforming to code style in some examples.
2 parents 0c1b26d + 0aa901e commit 4874d38

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

javascript/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,17 +33,17 @@ Don't use magic numbers
3333

3434
````javascript
3535
// bad: what was 3 again? Text node? Comment?
36-
if(el.nodeType === 3) { ... }
36+
if (el.nodeType === 3) { ... }
3737

3838
// bad: The reader doesn't know why we chose 7, and if we change 7 with 8, we'll have to carefully search and replace all occurrences
39-
if($('.blah').length === 7) { ... }
39+
if ($('.blah').length === 7) { ... }
4040

4141
// good
4242

43-
if(el.nodeType === Node.TEXT_NODE) { ... }
43+
if (el.nodeType === Node.TEXT_NODE) { ... }
4444

4545
// good
46-
if($('.blah').length === defaultRoomCount) { ... }
46+
if ($('.blah').length === defaultRoomCount) { ... }
4747
````
4848

4949
Declare variables with var

0 commit comments

Comments
 (0)