mirror of
https://github.com/airbnb/javascript.git
synced 2026-01-14 08:38:08 -05:00
[conditionals] update wording, es5 version
This commit is contained in:
@@ -1059,7 +1059,7 @@
|
||||
## Comparison Operators & Equality
|
||||
|
||||
- Use `===` and `!==` over `==` and `!=`.
|
||||
- Comparison operators are evaluated in `if` statements using coercion with the `ToBoolean` method and always follow these simple rules:
|
||||
- Conditional statements such as the `if` statement evaulate their expression using coercion with the `ToBoolean` abstract method and always follow these simple rules:
|
||||
|
||||
+ **Objects** evaluate to **true**
|
||||
+ **Undefined** evaluates to **false**
|
||||
|
||||
@@ -572,7 +572,7 @@
|
||||
## Comparison Operators & Equality
|
||||
|
||||
- Use `===` and `!==` over `==` and `!=`.
|
||||
- Comparison operators are evaluated using coercion with the `ToBoolean` method and always follow these simple rules:
|
||||
- Conditional statements such as the `if` statement evaulate their expression using coercion with the `ToBoolean` abstract method and always follow these simple rules:
|
||||
|
||||
+ **Objects** evaluate to **true**
|
||||
+ **Undefined** evaluates to **false**
|
||||
|
||||
Reference in New Issue
Block a user