Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
20834134
Commit
20834134
authored
Oct 24, 2015
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update changelog and small fixes to coding style guide
parent
a1a89f7c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
docs/CHANGES.rst
docs/CHANGES.rst
+1
-0
docs/source/style_guide.rst
docs/source/style_guide.rst
+8
-7
No files found.
docs/CHANGES.rst
View file @
20834134
...
...
@@ -5,6 +5,7 @@ Changelog
------------------
* #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]
0.9.6 (2015-10-12)
...
...
docs/source/style_guide.rst
View file @
20834134
...
...
@@ -6,7 +6,7 @@ Software Style Guide
rely on a transpiler and still support older browsers.
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
conform to your expectations on how Javascript code should look like.
...
...
@@ -92,17 +92,18 @@ between:
This is to make a more explicit visual distinction between method declarations
and method invocations.
Checking for equality
---------------------
Javascript has a strict ``===`` and less strict ``==`` equality operator. To
avoid subtle bugs when doing comparisons, always use the strict equality check.
Javascript has a strict ``===`` and less strict ``==`` equality operator. The
stricter equality operator also does type checking. To avoid subtle bugs when
doing comparisons, always use the strict equality check.
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:
...
...
@@ -121,8 +122,8 @@ Always enclose blocks in curly brackets
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
When writing an a block such as an ``if`` or ``while`` statement, always use
curly brackets around th
e block of code. Either
when not strictly required by
the compiler.
curly brackets around th
at block of code. Even
when not strictly required by
the compiler
(for example if its only one line inside the ``if`` statement)
.
For example, like this:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment