Merge pull request #12441 from Snuffleupagus/src-eslint-config

Re-factor how the ESLint `no-var` rule is enabled in the `src/` folder
This commit is contained in:
Tim van der Meij 2020-10-03 22:36:13 +02:00 committed by GitHub
commit 2823beba69
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
39 changed files with 25 additions and 26 deletions

View File

@ -1,6 +1,6 @@
{
"extends": [
"../../.eslintrc"
"../.eslintrc"
],
"rules": {

View File

@ -4,7 +4,7 @@
},
"extends": [
"../../.eslintrc"
"../.eslintrc"
],
"env": {

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import {
AnnotationBorderStyleType,

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
// Table C-2
const QeTable = [

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { warn } from "../shared/util.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { Dict, isDict } from "./primitives.js";
import { CCITTFaxDecoder } from "./ccitt.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
bytesToString,

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
// prettier-ignore
const ISOAdobeCharset = [

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import {
arrayByteLength,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
CMapCompressionType,

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { assert, BaseException, warn } from "../shared/util.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
bytesToString,

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import {
assert,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
AbortException,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
bytesToString,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
assert,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { Dict, isDict, isStream, Ref } from "./primitives.js";
import {

View File

@ -13,6 +13,7 @@
* limitations under the License.
*/
/* no-babel-preset */
/* eslint-disable no-var */
var getLookupTableFactory = require("./core_utils.js").getLookupTableFactory;

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { assert, FormatError, ImageKind, info, warn } from "../shared/util.js";
import { isName, isStream, Name } from "./primitives.js";

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { assert, info, shadow, unreachable } from "../shared/util.js";
import { RefSetCache } from "./primitives.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { BaseException, shadow } from "../shared/util.js";
import { log2, readInt8, readUint16, readUint32 } from "./core_utils.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { assert, BaseException, warn } from "../shared/util.js";
import { readUint16 } from "./core_utils.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { BaseException, info, warn } from "../shared/util.js";
import { log2, readUint16, readUint32 } from "./core_utils.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { getLookupTableFactory } from "./core_utils.js";

View File

@ -16,7 +16,6 @@
* Based on https://code.google.com/p/smhasher/wiki/MurmurHash3.
* Hashes roughly 100 KB per millisecond on i7 3.4 GHz.
*/
/* eslint no-var: error */
import { isArrayBuffer, isString } from "../shared/util.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
assert,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { assert, ImageKind, OPS, warn } from "../shared/util.js";

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import {
Ascii85Stream,

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
assert,

View File

@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* uses XRef */
/* eslint-disable no-var */
import { assert, unreachable } from "../shared/util.js";

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { FormatError, shadow } from "../shared/util.js";
import { EOF } from "./primitives.js";

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { getLookupTableFactory } from "./core_utils.js";

View File

@ -18,6 +18,7 @@
* of XPDF's implementation, made available under the Apache 2.0 open source
* license.
*/
/* eslint-disable no-var */
import { FormatError, stringToBytes, unreachable } from "../shared/util.js";
import { isDict } from "./primitives.js";

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import { getEncoding } from "./encodings.js";
import { isWhiteSpace } from "./core_utils.js";

View File

@ -13,6 +13,7 @@
* limitations under the License.
*/
/* no-babel-preset */
/* eslint-disable no-var */
var getLookupTableFactory = require("./core_utils.js").getLookupTableFactory;

View File

@ -12,6 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint-disable no-var */
import {
AbortException,

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { assert } from "../shared/util.js";

View File

@ -12,7 +12,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* eslint no-var: error */
import { bytesToString, escapeString, warn } from "../shared/util.js";
import { Dict, isDict, isName, isRef, isStream, Name } from "./primitives.js";

View File

@ -1,10 +0,0 @@
{
"extends": [
"../../.eslintrc"
],
"rules": {
// ECMAScript 6
"no-var": "error",
},
}