Skip to content

Commit

Permalink
Simplify eslint config and remove unused variables (bvaughn#951)
Browse files Browse the repository at this point in the history
  • Loading branch information
TrySound authored Jan 6, 2018
1 parent 0be33a3 commit 959d550
Show file tree
Hide file tree
Showing 6 changed files with 101 additions and 90 deletions.
17 changes: 7 additions & 10 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
{
"extends": [
"fbjs"
],
"parser": "babel-eslint",
"plugins": [
"prettier",
"react"
],
"parser": "babel-eslint",
"extends": [
"fbjs",
"eslint:recommended",
"plugin:prettier/recommended"
],
"rules": {
"max-len": 0
},
"env": {
"node": true,
"browser": true
"no-console": 0
}
}
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,16 +111,16 @@
"codemirror": "^5.18.0",
"cross-env": "^5.0.1",
"css-loader": "^0.28.7",
"eslint": "^4.2.0",
"eslint-config-fbjs": "^2.0.0",
"eslint-config-prettier": "^2.3.0",
"eslint": "^4.14.0",
"eslint-config-fbjs": "^2.0.1",
"eslint-config-prettier": "^2.9.0",
"eslint-config-react": "^1.1.7",
"eslint-plugin-babel": "^4.1.2",
"eslint-plugin-flowtype": "^2.35.0",
"eslint-plugin-jsx-a11y": "^6.0.2",
"eslint-plugin-prettier": "^2.1.2",
"eslint-plugin-react": "^7.1.0",
"eslint-plugin-relay": "^0.0.19",
"eslint-plugin-flowtype": "^2.40.1",
"eslint-plugin-jsx-a11y": "^6.0.3",
"eslint-plugin-prettier": "^2.4.0",
"eslint-plugin-react": "^7.5.1",
"eslint-plugin-relay": "^0.0.20",
"express": "^4.13.3",
"extract-text-webpack-plugin": "^3.0.2",
"file-loader": "^1.1.6",
Expand Down
2 changes: 0 additions & 2 deletions source/WindowScroller/WindowScroller.jest.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import React from 'react';
import {findDOMNode} from 'react-dom';
import ReactDOMServer from 'react-dom/server';
import {render} from '../TestUtils';
import WindowScroller, {IS_SCROLLING_TIMEOUT} from './WindowScroller';

Expand Down Expand Up @@ -199,7 +198,6 @@ describe('WindowScroller', () => {
it('should update :scrollTop when window is scrolled', async () => {
const renderFn = jest.fn();
const component = render(getMarkup({renderFn}));
const rendered = findDOMNode(component);

// Initial load of the component should have 0 scrollTop
expect(renderFn).lastCalledWith(
Expand Down
1 change: 0 additions & 1 deletion source/WindowScroller/WindowScroller.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// @flow

import * as React from 'react';
import PropTypes from 'prop-types';
import ReactDOM from 'react-dom';
import {
registerScrollListener,
Expand Down
1 change: 0 additions & 1 deletion source/jest-global-teardown.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
const os = require('os');
const util = require('util');
const path = require('path');
const puppeteer = require('puppeteer');
const rimraf = require('rimraf');

const del = util.promisify(rimraf);
Expand Down
154 changes: 86 additions & 68 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,9 @@ acorn@^5.0.0, acorn@^5.1.2:
version "5.2.1"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.2.1.tgz#317ac7821826c22c702d66189ab8359675f135d7"

acorn@^5.0.1:
version "5.1.1"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.1.1.tgz#53fe161111f912ab999ee887a90a0bc52822fd75"
acorn@^5.2.1:
version "5.3.0"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.3.0.tgz#7446d39459c54fb49a80e6ee6478149b940ec822"

agent-base@^4.1.0:
version "4.1.2"
Expand All @@ -144,7 +144,7 @@ ajv@^4.7.0, ajv@^4.9.1:
co "^4.6.0"
json-stable-stringify "^1.0.1"

ajv@^5.0.0, ajv@^5.2.0:
ajv@^5.0.0:
version "5.2.2"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.2.2.tgz#47c68d69e86f5d953103b0074a9430dc63da5e39"
dependencies:
Expand All @@ -153,7 +153,7 @@ ajv@^5.0.0, ajv@^5.2.0:
json-schema-traverse "^0.3.0"
json-stable-stringify "^1.0.1"

ajv@^5.1.0, ajv@^5.1.5:
ajv@^5.1.0, ajv@^5.1.5, ajv@^5.3.0:
version "5.5.2"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965"
dependencies:
Expand Down Expand Up @@ -2518,6 +2518,12 @@ doctrine@^2.0.0:
esutils "^2.0.2"
isarray "^1.0.0"

doctrine@^2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.0.2.tgz#68f96ce8efc56cc42651f1faadb4f175273b0075"
dependencies:
esutils "^2.0.2"

dom-converter@~0.1:
version "0.1.4"
resolved "https://registry.yarnpkg.com/dom-converter/-/dom-converter-0.1.4.tgz#a45ef5727b890c9bffe6d7c876e7b19cb0e17f3b"
Expand Down Expand Up @@ -2773,13 +2779,13 @@ escope@^3.6.0:
esrecurse "^4.1.0"
estraverse "^4.1.1"

eslint-config-fbjs@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/eslint-config-fbjs/-/eslint-config-fbjs-2.0.0.tgz#9f6ed690f500c2d750bf651e0cf1c65cf10b1c14"
eslint-config-fbjs@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/eslint-config-fbjs/-/eslint-config-fbjs-2.0.1.tgz#395896fd740e0e28dc1c2072e3bc982e88247df5"

eslint-config-prettier@^2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-2.3.0.tgz#b75b1eabea0c8b97b34403647ee25db349b9d8a0"
eslint-config-prettier@^2.9.0:
version "2.9.0"
resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-2.9.0.tgz#5ecd65174d486c22dff389fe036febf502d468a3"
dependencies:
get-stdin "^5.0.1"

Expand All @@ -2791,44 +2797,45 @@ eslint-plugin-babel@^4.1.2:
version "4.1.2"
resolved "https://registry.yarnpkg.com/eslint-plugin-babel/-/eslint-plugin-babel-4.1.2.tgz#79202a0e35757dd92780919b2336f1fa2fe53c1e"

eslint-plugin-flowtype@^2.35.0:
version "2.35.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype/-/eslint-plugin-flowtype-2.35.0.tgz#d17494f0ae8b727c632d8b9d4b4a848e7e0c04af"
eslint-plugin-flowtype@^2.40.1:
version "2.40.1"
resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype/-/eslint-plugin-flowtype-2.40.1.tgz#f78a8e6a4cc6da831dd541eb61e803ff0279b796"
dependencies:
lodash "^4.15.0"

eslint-plugin-jsx-a11y@^6.0.2:
version "6.0.2"
resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.0.2.tgz#659277a758b036c305a7e4a13057c301cd3be73f"
eslint-plugin-jsx-a11y@^6.0.3:
version "6.0.3"
resolved "https://registry.yarnpkg.com/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.0.3.tgz#54583d1ae442483162e040e13cc31865465100e5"
dependencies:
aria-query "^0.7.0"
array-includes "^3.0.3"
ast-types-flow "0.0.7"
axobject-query "^0.1.0"
damerau-levenshtein "^1.0.0"
emoji-regex "^6.1.0"
jsx-ast-utils "^1.4.0"
jsx-ast-utils "^2.0.0"

eslint-plugin-prettier@^2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-2.1.2.tgz#4b90f4ee7f92bfbe2e926017e1ca40eb628965ea"
eslint-plugin-prettier@^2.4.0:
version "2.4.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-2.4.0.tgz#85cab0775c6d5e3344ef01e78d960f166fb93aae"
dependencies:
fast-diff "^1.1.1"
jest-docblock "^20.0.1"
jest-docblock "^21.0.0"

eslint-plugin-react@^7.1.0:
version "7.1.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.1.0.tgz#27770acf39f5fd49cd0af4083ce58104eb390d4c"
eslint-plugin-react@^7.5.1:
version "7.5.1"
resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.5.1.tgz#52e56e8d80c810de158859ef07b880d2f56ee30b"
dependencies:
doctrine "^2.0.0"
has "^1.0.1"
jsx-ast-utils "^1.4.1"
jsx-ast-utils "^2.0.0"
prop-types "^15.6.0"

eslint-plugin-relay@^0.0.19:
version "0.0.19"
resolved "https://registry.yarnpkg.com/eslint-plugin-relay/-/eslint-plugin-relay-0.0.19.tgz#68767f79f19bf81e2aa6a7ccf82fe30d65015efe"
eslint-plugin-relay@^0.0.20:
version "0.0.20"
resolved "https://registry.yarnpkg.com/eslint-plugin-relay/-/eslint-plugin-relay-0.0.20.tgz#3f36b13ff749fb754c5d6915937558b0ac1d2232"
dependencies:
graphql "^0.11.3"
graphql "^0.12.3"

eslint-scope@^3.7.1, eslint-scope@~3.7.1:
version "3.7.1"
Expand All @@ -2841,49 +2848,53 @@ eslint-visitor-keys@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d"

eslint@^4.2.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.2.0.tgz#a2b3184111b198e02e9c7f3cca625a5e01c56b3d"
eslint@^4.14.0:
version "4.14.0"
resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.14.0.tgz#96609768d1dd23304faba2d94b7fefe5a5447a82"
dependencies:
ajv "^5.2.0"
ajv "^5.3.0"
babel-code-frame "^6.22.0"
chalk "^1.1.3"
chalk "^2.1.0"
concat-stream "^1.6.0"
debug "^2.6.8"
doctrine "^2.0.0"
cross-spawn "^5.1.0"
debug "^3.1.0"
doctrine "^2.0.2"
eslint-scope "^3.7.1"
espree "^3.4.3"
eslint-visitor-keys "^1.0.0"
espree "^3.5.2"
esquery "^1.0.0"
estraverse "^4.2.0"
esutils "^2.0.2"
file-entry-cache "^2.0.0"
functional-red-black-tree "^1.0.1"
glob "^7.1.2"
globals "^9.17.0"
globals "^11.0.1"
ignore "^3.3.3"
imurmurhash "^0.1.4"
inquirer "^3.0.6"
is-resolvable "^1.0.0"
js-yaml "^3.8.4"
json-stable-stringify "^1.0.1"
js-yaml "^3.9.1"
json-stable-stringify-without-jsonify "^1.0.1"
levn "^0.3.0"
lodash "^4.17.4"
minimatch "^3.0.2"
mkdirp "^0.5.1"
natural-compare "^1.4.0"
optionator "^0.8.2"
path-is-inside "^1.0.2"
pluralize "^4.0.0"
pluralize "^7.0.0"
progress "^2.0.0"
require-uncached "^1.0.3"
semver "^5.3.0"
strip-ansi "^4.0.0"
strip-json-comments "~2.0.1"
table "^4.0.1"
text-table "~0.2.0"

espree@^3.4.3:
version "3.4.3"
resolved "https://registry.yarnpkg.com/espree/-/espree-3.4.3.tgz#2910b5ccd49ce893c2ffffaab4fd8b3a31b82374"
espree@^3.5.2:
version "3.5.2"
resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.2.tgz#756ada8b979e9dcfcdb30aad8d1a9304a905e1ca"
dependencies:
acorn "^5.0.1"
acorn "^5.2.1"
acorn-jsx "^3.0.0"

esprima@^2.6.0:
Expand Down Expand Up @@ -3415,6 +3426,10 @@ function-bind@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d"

functional-red-black-tree@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327"

gauge@~2.6.0:
version "2.6.0"
resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.6.0.tgz#d35301ad18e96902b4751dcbbe40f4218b942a46"
Expand Down Expand Up @@ -3532,11 +3547,15 @@ globals@^10.0.0:
version "10.4.0"
resolved "https://registry.yarnpkg.com/globals/-/globals-10.4.0.tgz#5c477388b128a9e4c5c5d01c7a2aca68c68b2da7"

globals@^11.0.1:
version "11.1.0"
resolved "https://registry.yarnpkg.com/globals/-/globals-11.1.0.tgz#632644457f5f0e3ae711807183700ebf2e4633e4"

globals@^9.0.0:
version "9.13.0"
resolved "https://registry.yarnpkg.com/globals/-/globals-9.13.0.tgz#d97706b61600d8dbe94708c367d3fdcf48470b8f"

globals@^9.17.0, globals@^9.18.0:
globals@^9.18.0:
version "9.18.0"
resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a"

Expand Down Expand Up @@ -3573,9 +3592,9 @@ graceful-fs@^4.1.2, graceful-fs@^4.1.4, graceful-fs@^4.1.6:
version "1.0.1"
resolved "https://registry.yarnpkg.com/graceful-readlink/-/graceful-readlink-1.0.1.tgz#4cafad76bc62f02fa039b2f94e9a3dd3a391a725"

graphql@^0.11.3:
version "0.11.7"
resolved "https://registry.yarnpkg.com/graphql/-/graphql-0.11.7.tgz#e5abaa9cb7b7cccb84e9f0836bf4370d268750c6"
graphql@^0.12.3:
version "0.12.3"
resolved "https://registry.yarnpkg.com/graphql/-/graphql-0.12.3.tgz#11668458bbe28261c0dcb6e265f515ba79f6ce07"
dependencies:
iterall "1.1.3"

Expand Down Expand Up @@ -4348,9 +4367,9 @@ jest-diff@^22.0.3:
jest-get-type "^22.0.3"
pretty-format "^22.0.3"

jest-docblock@^20.0.1:
version "20.0.3"
resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-20.0.3.tgz#17bea984342cc33d83c50fbe1545ea0efaa44712"
jest-docblock@^21.0.0:
version "21.2.0"
resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-21.2.0.tgz#51529c3b30d5fd159da60c27ceedc195faf8d414"

jest-docblock@^22.0.3:
version "22.0.3"
Expand Down Expand Up @@ -4553,7 +4572,7 @@ js-tokens@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b"

js-yaml@^3.4.3:
js-yaml@^3.4.3, js-yaml@^3.9.1:
version "3.10.0"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc"
dependencies:
Expand All @@ -4567,13 +4586,6 @@ js-yaml@^3.7.0:
argparse "^1.0.7"
esprima "^2.6.0"

js-yaml@^3.8.4:
version "3.9.0"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.9.0.tgz#4ffbbf25c2ac963b8299dc74da7e3740de1c18ce"
dependencies:
argparse "^1.0.7"
esprima "^4.0.0"

js-yaml@~3.6.1:
version "3.6.1"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.6.1.tgz#6e5fe67d8b205ce4d22fad05b7781e8dadcc4b30"
Expand Down Expand Up @@ -4638,6 +4650,10 @@ [email protected]:
version "0.2.3"
resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13"

json-stable-stringify-without-jsonify@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651"

json-stable-stringify@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af"
Expand Down Expand Up @@ -4688,9 +4704,11 @@ jsprim@^1.2.2:
json-schema "0.2.3"
verror "1.3.6"

jsx-ast-utils@^1.4.0, jsx-ast-utils@^1.4.1:
version "1.4.1"
resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-1.4.1.tgz#3867213e8dd79bf1e8f2300c0cfc1efb182c0df1"
jsx-ast-utils@^2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-2.0.1.tgz#e801b1b39985e20fffc87b40e3748080e2dcac7f"
dependencies:
array-includes "^3.0.3"

kefir@^3.7.3:
version "3.8.0"
Expand Down Expand Up @@ -5592,9 +5610,9 @@ pkg-dir@^2.0.0:
dependencies:
find-up "^2.1.0"

pluralize@^4.0.0:
version "4.0.0"
resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-4.0.0.tgz#59b708c1c0190a2f692f1c7618c446b052fd1762"
pluralize@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777"

pn@^1.0.0:
version "1.0.0"
Expand Down

0 comments on commit 959d550

Please sign in to comment.