Skip to content
Browse files

tweaking multi-line ternary

I’m making this change to pass JSHint. Additionally, doing it this way
means that none of the lines are valid expressions by themselves.
Keeping the `?` on the first line disables that line from existing in
isolation.
  • Loading branch information...
1 parent f9d4be0 commit df1b47b9bf137cf50341152202c92c6ee2cded44 @jmonster jmonster committed
Showing with 3 additions and 3 deletions.
  1. +3 −3 README.md
View
6 README.md
@@ -238,9 +238,9 @@ The ternary operator should not be used on a single line. Split it up into multi
*Right:*
```js
-var foo = (a === b)
- ? 1
- : 2;
+var foo = (a === b) ?
+ 1 :
+ 2;
```
*Wrong:*

0 comments on commit df1b47b

Please sign in to comment.
Something went wrong with that request. Please try again.