-
Notifications
You must be signed in to change notification settings - Fork 46.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
Conflicts: src/renderers/dom/shared/CSSProperty.js
- Loading branch information
Showing
672 changed files
with
17,126 additions
and
19,120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,59 @@ | ||
--- | ||
parser: esprima-fb | ||
parser: babel-eslint | ||
|
||
env: | ||
browser: true | ||
node: true | ||
extends: | ||
- ./node_modules/fbjs-scripts/eslint/.eslintrc | ||
|
||
globals: | ||
__DEV__: true | ||
plugins: | ||
- react | ||
- react-internal | ||
|
||
# We're stricter than the default config, mostly. We'll override a few rules and | ||
# then enable some React specific ones. | ||
rules: | ||
# ERRORS | ||
space-before-blocks: 2 | ||
indent: [2, 2, indentSwitchCase: true] | ||
brace-style: 2 | ||
space-after-keywords: 2 | ||
strict: 2 | ||
# We actually have a transform to support this and we fix this for bundled | ||
# releases but not for the npm package, so enforce it strictly | ||
no-comma-dangle: 2 | ||
# Make this a warning for now. We do this in a few places so we might need to | ||
# disable | ||
no-unused-expressions: 2 | ||
block-scoped-var: 2 | ||
eol-last: 2 | ||
dot-notation: 2 | ||
accessor-pairs: 0 | ||
brace-style: [2, 1tbs] | ||
comma-dangle: [2, always-multiline] | ||
consistent-return: 2 | ||
no-unused-vars: [2, args: none] | ||
quotes: [2, 'single'] | ||
|
||
# WARNINGS | ||
# This is the only one that's hard to track since we don't lint just changes. | ||
max-len: [1, 80] | ||
|
||
# WISHLIST. One day... | ||
# We'll need a custom version of this that does a subset of the whole rule. | ||
# Otherwise this is just too noisy. | ||
# valid-jsdoc: 1 | ||
dot-location: [2, property] | ||
dot-notation: 2 | ||
eol-last: 2 | ||
indent: [2, 2, {SwitchCase: 1}] | ||
no-bitwise: 0 | ||
no-multi-spaces: 2 | ||
no-shadow: 2 | ||
no-unused-expressions: 2 | ||
no-unused-vars: [2, {args: none}] | ||
quotes: [2, single, avoid-escape] | ||
space-after-keywords: 2 | ||
space-before-blocks: 2 | ||
strict: [2, global] | ||
|
||
# DISABLED. These aren't compatible with our style | ||
# We use this for private/internal variables | ||
no-underscore-dangle: 0 | ||
# We pass constructors around / access them from members | ||
new-cap: 0 | ||
# We do this a lot. | ||
no-use-before-define: 0 | ||
# We do this in a few places to align values | ||
key-spacing: 0 | ||
# JSX | ||
# Our transforms set this automatically | ||
react/display-name: 0 | ||
react/jsx-boolean-value: [2, always] | ||
react/jsx-no-undef: 2 | ||
react/jsx-quotes: [2, double] | ||
# We don't care to do this | ||
react/jsx-sort-prop-types: 0 | ||
react/jsx-sort-props: 0 | ||
react/jsx-uses-react: 2 | ||
react/jsx-uses-vars: 2 | ||
# It's easier to test some things this way | ||
react/no-did-mount-set-state: 0 | ||
react/no-did-update-set-state: 0 | ||
# We define multiple components in test files | ||
react/no-multi-comp: 0 | ||
react/no-unknown-property: 2 | ||
# This isn't useful in our test code | ||
react/prop-types: 0 | ||
react/react-in-jsx-scope: 2 | ||
react/self-closing-comp: 2 | ||
# We don't care to do this | ||
react/sort-comp: 0 | ||
react/wrap-multilines: [2, {declaration: false, assignment: false}] | ||
|
||
# DISABLED. These currently cause errors when running. | ||
no-multi-spaces: 0 | ||
# CUSTOM RULES | ||
# the second argument of warning/invariant should be a literal string | ||
react-internal/warning-and-invariant-args: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.