summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-05-16 16:57:05 -0500
committerMike Greiling <mike@pixelcog.com>2017-05-16 16:57:05 -0500
commit337acf4be340960efc1b97e2bf298314f9ea16bf (patch)
tree70b716644e2f27a524ede0c2928040a939e57d3e
parentf68a3f3f4b2c24f39c626b49f78255d632cb1420 (diff)
downloadgitlab-ce-337acf4be340960efc1b97e2bf298314f9ea16bf.tar.gz
fix eslint failures
-rw-r--r--app/assets/javascripts/lib/utils/datetime_utility.js3
-rw-r--r--spec/javascripts/activities_spec.js2
-rw-r--r--spec/javascripts/boards/board_card_spec.js2
-rw-r--r--spec/javascripts/merge_request_tabs_spec.js2
-rw-r--r--spec/javascripts/project_title_spec.js2
5 files changed, 5 insertions, 6 deletions
diff --git a/app/assets/javascripts/lib/utils/datetime_utility.js b/app/assets/javascripts/lib/utils/datetime_utility.js
index 566b05628c0..b2f48049bb4 100644
--- a/app/assets/javascripts/lib/utils/datetime_utility.js
+++ b/app/assets/javascripts/lib/utils/datetime_utility.js
@@ -102,8 +102,7 @@ window.dateFormat = dateFormat;
};
w.gl.utils.updateTimeagoText = function(el) {
- const timeago = gl.utils.getTimeago();
- const formattedDate = timeago.format(el.getAttribute('datetime'), 'gl_en');
+ const formattedDate = gl.utils.getTimeago().format(el.getAttribute('datetime'), 'gl_en');
if (el.textContent !== formattedDate) {
el.textContent = formattedDate;
diff --git a/spec/javascripts/activities_spec.js b/spec/javascripts/activities_spec.js
index b6e7b4717d5..e8c5f721423 100644
--- a/spec/javascripts/activities_spec.js
+++ b/spec/javascripts/activities_spec.js
@@ -1,6 +1,6 @@
/* eslint-disable no-unused-expressions, no-prototype-builtins, no-new, no-shadow, max-len */
-import 'vendor/jquery.endless-scroll.js';
+import 'vendor/jquery.endless-scroll';
import '~/pager';
import '~/activities';
diff --git a/spec/javascripts/boards/board_card_spec.js b/spec/javascripts/boards/board_card_spec.js
index ad5d725cf1b..447b244c71f 100644
--- a/spec/javascripts/boards/board_card_spec.js
+++ b/spec/javascripts/boards/board_card_spec.js
@@ -11,7 +11,7 @@ import '~/boards/models/assignee';
import '~/boards/models/list';
import '~/boards/models/label';
import '~/boards/stores/boards_store';
-const boardCard = require('~/boards/components/board_card').default;
+import boardCard from '~/boards/components/board_card';
import './mock_data';
describe('Issue card', () => {
diff --git a/spec/javascripts/merge_request_tabs_spec.js b/spec/javascripts/merge_request_tabs_spec.js
index ce0335787b7..3d1706aab68 100644
--- a/spec/javascripts/merge_request_tabs_spec.js
+++ b/spec/javascripts/merge_request_tabs_spec.js
@@ -1,7 +1,7 @@
/* eslint-disable no-var, comma-dangle, object-shorthand */
import '~/merge_request_tabs';
-import '~/commit/pipelines/pipelines_bundle.js';
+import '~/commit/pipelines/pipelines_bundle';
import '~/breakpoints';
import '~/lib/utils/common_utils';
import '~/diff';
diff --git a/spec/javascripts/project_title_spec.js b/spec/javascripts/project_title_spec.js
index 9f6e7e918ff..3dba2e817ff 100644
--- a/spec/javascripts/project_title_spec.js
+++ b/spec/javascripts/project_title_spec.js
@@ -1,7 +1,7 @@
/* eslint-disable space-before-function-paren, no-unused-expressions, no-return-assign, no-param-reassign, no-var, new-cap, wrap-iife, no-unused-vars, quotes, jasmine/no-expect-in-setup-teardown, max-len */
/* global Project */
-import 'select2/select2.js';
+import 'select2/select2';
import '~/gl_dropdown';
import '~/api';
import '~/project_select';