Skip to content

Commit

Permalink
[Dev Deps] remove jscs and jshint
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Mar 7, 2019
1 parent 271142c commit 8ac5c6d
Show file tree
Hide file tree
Showing 10 changed files with 3 additions and 251 deletions.
175 changes: 0 additions & 175 deletions .jscs.json

This file was deleted.

7 changes: 0 additions & 7 deletions .jshintrc

This file was deleted.

3 changes: 0 additions & 3 deletions es6-sham.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,9 @@
}(this, function () {
'use strict';

/*jshint evil: true */
/* eslint-disable no-new-func */
var getGlobal = new Function('return this;');
/* eslint-enable no-new-func */
/*jshint evil: false */

var globals = getGlobal();
var Object = globals.Object;
Expand Down Expand Up @@ -67,7 +65,6 @@
(function () {
if (Object.setPrototypeOf) { return; }

/*jshint proto: true */
// @author Andrea Giammarchi - @WebReflection

var getOwnPropertyNames = Object.getOwnPropertyNames;
Expand Down
15 changes: 0 additions & 15 deletions es6-shim.js
Original file line number Diff line number Diff line change
Expand Up @@ -296,12 +296,9 @@

/* global document */
var domAll = (typeof document === 'undefined' || !document) ? null : document.all;
/* jshint eqnull:true */
var isNullOrUndefined = domAll == null ? function isNullOrUndefined(x) {
/* jshint eqnull:true */
return x == null;
} : function isNullOrUndefinedAndNotDocumentAll(x) {
/* jshint eqnull:true */
return x == null && x !== domAll;
};

Expand Down Expand Up @@ -1415,9 +1412,7 @@
if (receiver instanceof NumberShim && !valueOfSucceeds) {
return new OrigNumber(primValue);
}
/* jshint newcap: false */
return OrigNumber(primValue);
/* jshint newcap: true */
};
return NumberShim;
}());
Expand All @@ -1432,10 +1427,8 @@
});
/* globals Number: true */
/* eslint-disable no-undef, no-global-assign */
/* jshint -W020 */
Number = NumberShim;
Value.redefine(globals, 'Number', NumberShim);
/* jshint +W020 */
/* eslint-enable no-undef, no-global-assign */
/* globals Number: false */
}
Expand Down Expand Up @@ -1468,7 +1461,6 @@
// implementations skipped holes in sparse arrays. (Note that the
// implementations of find/findIndex indirectly use shimmed
// methods of Number, so this test has to happen down here.)
/*jshint elision: true */
/* eslint-disable no-sparse-arrays */
if ([, 1].find(function () { return true; }) === 1) {
overrideNative(Array.prototype, 'find', ArrayPrototypeShims.find);
Expand All @@ -1477,7 +1469,6 @@
overrideNative(Array.prototype, 'findIndex', ArrayPrototypeShims.findIndex);
}
/* eslint-enable no-sparse-arrays */
/*jshint elision: false */

var isEnumerableOn = Function.bind.call(Function.bind, Object.prototype.propertyIsEnumerable);
var ensureEnumerable = function ensureEnumerable(obj, prop) {
Expand Down Expand Up @@ -1840,10 +1831,8 @@
});
/* globals RegExp: true */
/* eslint-disable no-undef, no-global-assign */
/* jshint -W020 */
RegExp = RegExpShim;
Value.redefine(globals, 'RegExp', RegExpShim);
/* jshint +W020 */
/* eslint-enable no-undef, no-global-assign */
/* globals RegExp: false */
}
Expand Down Expand Up @@ -2215,12 +2204,10 @@
};
};
/*global process */
/* jscs:disable disallowMultiLineTernary */
var enqueue = ES.IsCallable(globals.setImmediate) ?
globals.setImmediate :
typeof process === 'object' && process.nextTick ? process.nextTick : makePromiseAsap() ||
(ES.IsCallable(makeZeroTimeout) ? makeZeroTimeout() : function (task) { setTimeout(task, 0); }); // fallback
/* jscs:enable disallowMultiLineTernary */

// Constants for Promise implementation
var PROMISE_IDENTITY = function (x) { return x; };
Expand Down Expand Up @@ -2699,9 +2686,7 @@
!getsThenSynchronously || hasBadResolverPromise) {
/* globals Promise: true */
/* eslint-disable no-undef, no-global-assign */
/* jshint -W020 */
Promise = PromiseShim;
/* jshint +W020 */
/* eslint-enable no-undef, no-global-assign */
/* globals Promise: false */
overrideNative(globals, 'Promise', PromiseShim);
Expand Down
15 changes: 2 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,8 @@
"test:sham": "mocha test-sham/*.js",
"test:native": "NO_ES6_SHIM=1 npm run tests-only",
"lint": "npm run lint:shim && npm run lint:sham",
"lint:shim": "npm run jshint:shim && npm run jscs:shim && npm run eslint:shim",
"lint:sham": "npm run jshint:sham && npm run jscs:sham && npm run eslint:sham",
"eslint": "npm run eslint:shim && npm run eslint:sham",
"eslint:shim": "eslint es6-shim.js test/*.js test/*/*.js",
"eslint:sham": "eslint es6-sham.js test-sham/*.js",
"jshint": "npm run jshint:shim && npm run jshint:sham",
"jshint:shim": "jshint es6-shim.js test/*.js test/*/*.js",
"jshint:sham": "jshint es6-sham.js test-sham/*.js",
"jscs": "npm run jscs:shim && npm run jscs:sham",
"jscs:shim": "jscs es6-shim.js test/*.js test/*/*.js",
"jscs:sham": "jscs es6-sham.js test-sham/*.js",
"lint:shim": "eslint es6-shim.js test/*.js test/*/*.js",
"lint:sham": "eslint es6-sham.js test-sham/*.js",
"minify": "npm run minify:shim && npm run minify:sham",
"minify:shim": "uglifyjs es6-shim.js --support-ie8 --keep-fnames --comments --source-map=es6-shim.map -m -b ascii_only=true,beautify=false > es6-shim.min.js",
"minify:sham": "uglifyjs es6-sham.js --support-ie8 --keep-fnames --comments --source-map=es6-sham.map -m -b ascii_only=true,beautify=false > es6-sham.min.js",
Expand Down Expand Up @@ -78,8 +69,6 @@
"grunt-contrib-connect": "^1.0.2",
"grunt-contrib-watch": "^1.1.0",
"grunt-saucelabs": "^8.6.3",
"jscs": "^3.0.7",
"jshint": "^2.9.6",
"mocha": "^3.5.3",
"promises-aplus-tests": "^2.1.2",
"promises-es6-tests": "^0.5.0",
Expand Down
4 changes: 1 addition & 3 deletions test-sham/function.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,8 @@ describe('Function', function () {
});

it('returns "anomymous" for Function functions', function () {
/* eslint no-new-func: 1 */
/* jshint evil: true */
// eslint-disable-next-line no-new-func
var func = identity(Function(''));
/* jshint evil: false */
expect(typeof func.name).to.equal('string');
expect(func.name === 'anonymous' || func.name === '').to.equal(true);

Expand Down
24 changes: 0 additions & 24 deletions test/array.js
Original file line number Diff line number Diff line change
Expand Up @@ -231,16 +231,10 @@ var runArrayTests = function (it) {
});

it('removes holes', function () {
/*jshint elision: true */
/* jscs:disable disallowSpaceBeforeComma */
/* jscs:disable requireSpaceAfterComma */
/* eslint-disable no-sparse-arrays */
var input = [0, , 2];
var result = Array.from([0, , 2]);
/* eslint-enable no-sparse-arrays */
/* jscs:enable requireSpaceAfterComma */
/* jscs:enable disallowSpaceBeforeComma */
/*jshint elision: false */
expect(1 in input).to.equal(false);
expect(1 in result).to.equal(true);
expect(result).to.eql([0, undefined, 2]);
Expand Down Expand Up @@ -387,14 +381,8 @@ var runArrayTests = function (it) {
});

it('should delete the target key if the source key is not present', function () {
/* jshint elision: true */
/* jscs:disable disallowSpaceBeforeComma */
/* jscs:disable requireSpaceAfterComma */
/* eslint-disable no-sparse-arrays */
expect([, 1, 2].copyWithin(1, 0)).to.eql([, , 1]);
/* jshint elision: false */
/* jscs:enable requireSpaceAfterComma */
/* jscs:enable disallowSpaceBeforeComma */
/* eslint-enable no-sparse-arrays */
});

Expand Down Expand Up @@ -475,15 +463,9 @@ var runArrayTests = function (it) {
});

it('should work with a sparse array', function () {
/*jshint elision: true */
/* jscs:disable disallowSpaceBeforeComma */
/* jscs:disable requireSpaceAfterComma */
/* eslint-disable no-sparse-arrays */
var obj = [1, , undefined];
/* eslint-enable no-sparse-arrays */
/* jscs:enable requireSpaceAfterComma */
/* jscs:enable disallowSpaceBeforeComma */
/*jshint elision: false */
expect(1 in obj).to.equal(false);
var seen = [];
var found = obj.find(function (item, idx) {
Expand Down Expand Up @@ -574,15 +556,9 @@ var runArrayTests = function (it) {
});

it('should work with a sparse array', function () {
/*jshint elision: true */
/* jscs:disable disallowSpaceBeforeComma */
/* jscs:disable requireSpaceAfterComma */
/* eslint-disable no-sparse-arrays */
var obj = [1, , undefined];
/* eslint-enable no-sparse-arrays */
/* jscs:enable requireSpaceAfterComma */
/* jscs:enable disallowSpaceBeforeComma */
/*jshint elision: false */
expect(1 in obj).to.equal(false);
var seen = [];
var foundIndex = obj.findIndex(function (item, idx) {
Expand Down
Loading

0 comments on commit 8ac5c6d

Please sign in to comment.