diff --git a/.eslintrc b/.eslintrc index 296ff1e04f..5d0b9f37dc 100644 --- a/.eslintrc +++ b/.eslintrc @@ -13,10 +13,13 @@ "import/no-unresolved": "off", "import/no-extraneous-dependencies": "off", "import/no-dynamic-require": "off", + "import/newline-after-import": "off", "no-bitwise": "off", "newline-per-chained-call": "off", "no-console": "off", "no-empty": ["error", { "allowEmptyCatch": true }], + "prefer-rest-params": "off", + "prefer-spread": "off", // "linebreak-style": "off", // "one-var": "off", @@ -94,12 +97,9 @@ "global-require": "off", "no-trailing-spaces": "off", "key-spacing": "off", - "import/newline-after-import": "off", "no-underscore-dangle": "off", - "prefer-spread": "off", // "no-multiple-empty-lines": "off", - "spaced-comment": "off", - "prefer-rest-params": "off", + // "spaced-comment": "off", // "space-in-parens": "off", // "block-spacing": "off", // "quote-props": "off", diff --git a/minifier.js b/minifier.js index dd367b58a7..8504312d22 100644 --- a/minifier.js +++ b/minifier.js @@ -35,7 +35,7 @@ Minifier.js.minify = function (scripts, minify, callback) { process.on('message', function (payload) { switch(payload.action) { case 'js': - Minifier.js.minify(payload.scripts, payload.minify, function (minified/*, sourceMap*/) { + Minifier.js.minify(payload.scripts, payload.minify, function (minified/* , sourceMap*/) { process.send({ type: 'end', // sourceMap: sourceMap, @@ -55,7 +55,7 @@ function minifyScripts(scripts, callback) { compress: false, }); - callback(minified.code/*, minified.map*/); + callback(minified.code/* , minified.map*/); } catch(err) { process.send({ type: 'error', diff --git a/public/src/admin/admin.js b/public/src/admin/admin.js index 8d1d56ab64..6b71868258 100644 --- a/public/src/admin/admin.js +++ b/public/src/admin/admin.js @@ -1,5 +1,4 @@ "use strict"; -/*global config, componentHandler, socket, app, bootbox, Slideout, NProgress, utils*/ (function () { var logoutTimer = 0; diff --git a/public/src/admin/extend/plugins.js b/public/src/admin/extend/plugins.js index ed99847dd3..df43edf5f7 100644 --- a/public/src/admin/extend/plugins.js +++ b/public/src/admin/extend/plugins.js @@ -29,7 +29,7 @@ define('admin/extend/plugins', ['jqueryui', 'translator'], function (jqueryui, t btn.html(buttonText); btn.toggleClass('btn-warning', status.active).toggleClass('btn-success', !status.active); - //clone it to active plugins tab + // clone it to active plugins tab if (status.active && !$('#active #' + pluginID).length) { $('#active ul').prepend(pluginEl.clone(true)); } diff --git a/public/src/admin/manage/categories.js b/public/src/admin/manage/categories.js index e953af0fba..c19a316060 100644 --- a/public/src/admin/manage/categories.js +++ b/public/src/admin/manage/categories.js @@ -127,7 +127,7 @@ define('admin/manage/categories', ['vendor/jquery/serializeObject/jquery.ba-seri function itemDragDidEnd(e) { var isCategoryUpdate = (newCategoryId != -1); - //Update needed? + // Update needed? if((e.newIndex != undefined && e.oldIndex != e.newIndex) || isCategoryUpdate) { var parentCategory = isCategoryUpdate ? sortables[newCategoryId] : sortables[e.from.dataset.cid]; var modified = {}; diff --git a/public/src/overrides.js b/public/src/overrides.js index 78b6e3b1db..5ffbdde3b0 100644 --- a/public/src/overrides.js +++ b/public/src/overrides.js @@ -40,7 +40,7 @@ if ('undefined' !== typeof window) { }); }; - //http://stackoverflow.com/questions/511088/use-javascript-to-place-cursor-at-end-of-text-in-text-input-element + // http://stackoverflow.com/questions/511088/use-javascript-to-place-cursor-at-end-of-text-in-text-input-element $.fn.putCursorAtEnd = function () { return this.each(function () { $(this).focus(); diff --git a/public/src/utils.js b/public/src/utils.js index 9016b8da65..eb9fec1e27 100644 --- a/public/src/utils.js +++ b/public/src/utils.js @@ -32,7 +32,7 @@ }); }, - //Adapted from http://stackoverflow.com/questions/5827612/node-js-fs-readdir-recursive-directory-search + // Adapted from http://stackoverflow.com/questions/5827612/node-js-fs-readdir-recursive-directory-search walk: function (dir, done) { var results = []; @@ -85,7 +85,7 @@ isLatin: /^[\w\d\s.,\-@]+$/, languageKeyRegex: /\[\[[\w]+:.+\]\]/, - //http://dense13.com/blog/2009/05/03/converting-string-to-slug-javascript/ + // http://dense13.com/blog/2009/05/03/converting-string-to-slug-javascript/ slugify: function (str, preserveCase) { if (!str) { return ''; @@ -272,7 +272,7 @@ }, findBootstrapEnvironment: function () { - //http://stackoverflow.com/questions/14441456/how-to-detect-which-device-view-youre-on-using-twitter-bootstrap-api + // http://stackoverflow.com/questions/14441456/how-to-detect-which-device-view-youre-on-using-twitter-bootstrap-api var envs = ['xs', 'sm', 'md', 'lg']; var $el = $('