mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-01-12 10:20:26 +00:00
Docs update
This commit is contained in:
parent
3b78ebb9c0
commit
e16453acbc
@ -1,4 +1,4 @@
|
|||||||
modified: 20141016083333808
|
modified: 20150430153333808
|
||||||
title: TiddlyWiki Coding Style Guidelines
|
title: TiddlyWiki Coding Style Guidelines
|
||||||
tags: dev
|
tags: dev
|
||||||
|
|
||||||
@ -25,9 +25,9 @@ See the following example for layout of basic JavaScript constructs:
|
|||||||
Multiline comments are used to introduce a block of code such as a function definition
|
Multiline comments are used to introduce a block of code such as a function definition
|
||||||
*/
|
*/
|
||||||
function demoFunction(param,more) {
|
function demoFunction(param,more) {
|
||||||
// Proper sentence capitalisation for comments
|
// Proper sentence capitalisation for comments; prefer strict equality checks
|
||||||
if(condition == "something") {
|
if(condition === "something") {
|
||||||
// No space between "if" and the brackets; always spaces around binary operators
|
// Always use braces, even when optional; no space between "if" and the brackets; always spaces around binary operators
|
||||||
something = somethingElse;
|
something = somethingElse;
|
||||||
myOtherFunction(one,two); // No whitespace within function parameters
|
myOtherFunction(one,two); // No whitespace within function parameters
|
||||||
do {
|
do {
|
||||||
|
Loading…
Reference in New Issue
Block a user