Skip to content

Commit

Permalink
Upgrading eslint-plugin-flowtype to be able to enable the flowtype/no…
Browse files Browse the repository at this point in the history
…-types-missing-file-annotation rule
  • Loading branch information
julienw committed Jun 30, 2017
1 parent df4b389 commit 3ccd330
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 5 deletions.
2 changes: 0 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ module.exports = {
"import/named": "error",
"prettier/prettier": ["error", { singleQuote: true, trailingComma: "es5" }],

"flowtype/no-types-missing-file-annotation": "off", // wait for https://github.com/gajus/eslint-plugin-flowtype/issues/248

// overriding recommended rules
"no-constant-condition": ["error", { checkLoops: false }],
"no-console": [ "error", { allow: ["log", "warn", "error"] } ],
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
"eslint": "^3.10.2",
"eslint-config-google": "^0.6.0",
"eslint-config-prettier": "^2.2.0",
"eslint-plugin-flowtype": "^2.30.0",
"eslint-plugin-flowtype": "^2.34.1",
"eslint-plugin-import": "^2.6.1",
"eslint-plugin-prettier": "^2.1.2",
"eslint-plugin-react": "^6.4.0",
Expand Down
2 changes: 1 addition & 1 deletion src/profile-logic/range-filters.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export function stringifyRangeFilters(arrayValue = []) {
.join('~');
}

export function getFormattedTimeLength(length: number) {
export function getFormattedTimeLength(length) {
if (length >= 10000) {
return `${(length / 1000).toFixed(0)} sec`;
}
Expand Down
2 changes: 2 additions & 0 deletions src/profile-logic/symbolication.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */

/* eslint-disable flowtype/no-types-missing-file-annotation */

import bisection from 'bisection';
import { resourceTypes } from './profile-data';
import type { Thread, IndexIntoFuncTable } from '../types/profile';
Expand Down
2 changes: 2 additions & 0 deletions src/test/fixtures/example-symbol-table.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */

// @flow

import { TextEncoder } from 'text-encoding';
import type { SymbolTableAsTuple } from '../../profile-logic/symbol-store-db';

Expand Down
2 changes: 2 additions & 0 deletions src/types/indexeddb.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
// Fixed the interfaces, especially added some genericity,
// and changed so that it can be simply `import`ed.

// @flow

// Implemented by window & worker
export interface IDBEnvironment {
indexedDB: IDBFactory,
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2277,7 +2277,7 @@ eslint-module-utils@^2.0.0:
debug "^2.6.8"
pkg-dir "^1.0.0"

eslint-plugin-flowtype@^2.30.0:
eslint-plugin-flowtype@^2.34.1:
version "2.34.1"
resolved "https://registry.yarnpkg.com/eslint-plugin-flowtype/-/eslint-plugin-flowtype-2.34.1.tgz#ea109175645b05d37baeac53b9b65066d79b9446"
dependencies:
Expand Down

0 comments on commit 3ccd330

Please sign in to comment.