Skip to content

Commit 7e078d6

Browse files
committed
Fix lint rules
The typeof one is a bit strange because the disable rule gets moved.
1 parent ba1299a commit 7e078d6

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

.eslintrc.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ module.exports = {
2323
'dot-notation': ERROR,
2424
'eol-last': ERROR,
2525
'eqeqeq': [ERROR, 'allow-null'],
26-
'indent': [ERROR, 2, {SwitchCase: 1}],
26+
'indent': OFF,
2727
'jsx-quotes': [ERROR, 'prefer-double'],
2828
'keyword-spacing': [ERROR, {after: true, before: true}],
2929
'no-bitwise': OFF,
@@ -33,9 +33,10 @@ module.exports = {
3333
'no-shadow': ERROR,
3434
'no-unused-expressions': ERROR,
3535
'no-unused-vars': [ERROR, {args: 'none'}],
36+
'no-useless-concat': OFF,
3637
'quotes': [ERROR, 'single', {avoidEscape: true, allowTemplateLiterals: true }],
3738
'space-before-blocks': ERROR,
38-
'space-before-function-paren': [ERROR, {anonymous: 'never', named: 'never'}],
39+
'space-before-function-paren': OFF,
3940

4041
// React & JSX
4142
// Our transforms set this automatically

src/renderers/shared/shared/event/SyntheticEvent.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
* @providesModule SyntheticEvent
1010
*/
1111

12+
/* eslint valid-typeof: 0 */
13+
1214
'use strict';
1315

1416
var PooledClass = require('PooledClass');
@@ -126,7 +128,6 @@ Object.assign(SyntheticEvent.prototype, {
126128
if (event.preventDefault) {
127129
event.preventDefault();
128130
} else if (typeof event.returnValue !== 'unknown') {
129-
// eslint-disable-line valid-typeof
130131
event.returnValue = false;
131132
}
132133
this.isDefaultPrevented = emptyFunction.thatReturnsTrue;
@@ -141,7 +142,6 @@ Object.assign(SyntheticEvent.prototype, {
141142
if (event.stopPropagation) {
142143
event.stopPropagation();
143144
} else if (typeof event.cancelBubble !== 'unknown') {
144-
// eslint-disable-line valid-typeof
145145
// The ChangeEventPlugin registers a "propertychange" event for
146146
// IE. This event does not support bubbling or cancelling, and
147147
// any references to cancelBubble throw "Member not found". A

src/renderers/shared/stack/reconciler/Transaction.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ var TransactionImpl = {
132132
e: E,
133133
f: F,
134134
) => G>(method: T, scope: any, a: A, b: B, c: C, d: D, e: E, f: F): G {
135-
// eslint-disable-line space-before-function-paren
136135
invariant(
137136
!this.isInTransaction(),
138137
'Transaction.perform(...): Cannot initialize a transaction when there ' +

0 commit comments

Comments
 (0)