Commit 20834134 authored by JC Brand's avatar JC Brand

Update changelog and small fixes to coding style guide

parent a1a89f7c
...@@ -5,6 +5,7 @@ Changelog ...@@ -5,6 +5,7 @@ Changelog
------------------ ------------------
* #493 Refactor previous bugfix and now an event is emitted when a roster push event from server happens. [teseo] * #493 Refactor previous bugfix and now an event is emitted when a roster push event from server happens. [teseo]
* #502. Chat room not opened in non_amd version. [rjanbiah]
* #505 Typo caused [object Object] in room info [gromiak] * #505 Typo caused [object Object] in room info [gromiak]
0.9.6 (2015-10-12) 0.9.6 (2015-10-12)
......
...@@ -6,7 +6,7 @@ Software Style Guide ...@@ -6,7 +6,7 @@ Software Style Guide
rely on a transpiler and still support older browsers. rely on a transpiler and still support older browsers.
Most of the style guide recommendations here come from Douglas Crockford's book Most of the style guide recommendations here come from Douglas Crockford's book
"Javascript, the good parts". `Javascript, the good parts <http://shop.oreilly.com/product/9780596517748.do>`_
This style guide is fairly opinionated. Some of these opinions perhaps don't This style guide is fairly opinionated. Some of these opinions perhaps don't
conform to your expectations on how Javascript code should look like. conform to your expectations on how Javascript code should look like.
...@@ -92,17 +92,18 @@ between: ...@@ -92,17 +92,18 @@ between:
This is to make a more explicit visual distinction between method declarations This is to make a more explicit visual distinction between method declarations
and method invocations. and method invocations.
Checking for equality Checking for equality
--------------------- ---------------------
Javascript has a strict ``===`` and less strict ``==`` equality operator. To Javascript has a strict ``===`` and less strict ``==`` equality operator. The
avoid subtle bugs when doing comparisons, always use the strict equality check. stricter equality operator also does type checking. To avoid subtle bugs when
doing comparisons, always use the strict equality check.
Curly brackets Curly brackets
-------------- --------------
Curly brackets come on the same lines as the ``if`` and ``else`` keywords. Curly brackets must appear on the same lines as the ``if`` and ``else`` keywords.
The closing curly bracket appears on its own line.
For example: For example:
...@@ -121,8 +122,8 @@ Always enclose blocks in curly brackets ...@@ -121,8 +122,8 @@ Always enclose blocks in curly brackets
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
When writing an a block such as an ``if`` or ``while`` statement, always use When writing an a block such as an ``if`` or ``while`` statement, always use
curly brackets around the block of code. Either when not strictly required by curly brackets around that block of code. Even when not strictly required by
the compiler. the compiler (for example if its only one line inside the ``if`` statement).
For example, like this: For example, like this:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment