Skip to content

Commit d8034dc

Browse files
author
Antonio Miranda
committed
Update examples and improve description
Added 'yes' 'no' examples and updated the *Optional Commas* description as sugested by @mjrusso
1 parent f6dbe68 commit d8034dc

File tree

1 file changed

+14
-7
lines changed

1 file changed

+14
-7
lines changed

README.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -73,16 +73,23 @@ Do not include trailing whitespace on any lines.
7373
<a name="optional_commas"/>
7474
### Optional Commas
7575

76-
Avoid the use of commas before newlines when each property of an Object or Array is listed on its own line.
76+
Avoid the use of commas before newlines when properties or elements of an Object or Array are listed on separate lines.
7777

7878
```coffeescript
79-
bitlist = [
80-
1, 0, 1
81-
1, 1, 0
79+
# Yes
80+
foo = [
81+
'some'
82+
'string'
83+
'values'
8284
]
83-
brother:
84-
name: "Max"
85-
age: 11
85+
bar:
86+
label: 'test'
87+
value: 87
88+
89+
# No
90+
foo = ['some', 'string', 'values']
91+
bar:
92+
label: 'test', value: 87
8693
```
8794

8895
<a name="encoding"/>

0 commit comments

Comments
 (0)