Please sign in to comment.
tools,lib: enable strict equality lint rule
Enablie a lint rule to require `===` and `!==` instead of `==` and `!=` except in some well-defined cases: * comparing against `null` as a shorthand for also checking for `undefined` * comparing the result of `typeof` * comparing literal values In cases where `==` or `!=` are being used as optimizations, use an ESLint comment to disable the `eqeqeq` rule for that line explicitly. I rather like this because it's a signal that the usage is intentional and not a mistake. PR-URL: #12446 Reviewed-By: Benjamin Gruenbaum <firstname.lastname@example.org> Reviewed-By: Anna Henningsen <email@example.com> Reviewed-By: Gibson Fahnestock <firstname.lastname@example.org> Reviewed-By: Luigi Pinca <email@example.com> Reviewed-By: Colin Ihrig <firstname.lastname@example.org> Reviewed-By: James M Snell <email@example.com>
- Loading branch information...
Showing with 13 additions and 4 deletions.