Commit a91ef140 authored by Mark Florian's avatar Mark Florian

Merge branch 'renovate/major-eslint-and-related' into 'master'

Update ESLint and related (major)

See merge request gitlab-org/gitlab!53367
parents e0807693 35a069ae
......@@ -2,7 +2,7 @@ import Vue from 'vue';
import StatisticsPanelApp from './components/app.vue';
import createStore from './store';
export default function (el) {
export default function initStatisticsPanel(el) {
if (!el) {
return false;
}
......
......@@ -117,7 +117,6 @@ const boardsStore = {
},
updateNewListDropdown(listId) {
// eslint-disable-next-line no-unused-expressions
document
.querySelector(`.js-board-list-${getIdFromGraphQLId(listId)}`)
?.classList.remove('is-active');
......
......@@ -5,7 +5,7 @@ import App from './components/app.vue';
Vue.use(VueApollo);
export default function () {
export default function initIssuableSuggestions() {
const el = document.getElementById('js-suggestions');
const issueTitle = document.getElementById('issue_title');
const { projectPath } = el.dataset;
......
......@@ -71,7 +71,7 @@ if (gon?.disable_animations) {
// inject test utilities if necessary
if (process.env.NODE_ENV !== 'production' && gon?.test_env) {
disableJQueryAnimations();
import(/* webpackMode: "eager" */ './test_utils/'); // eslint-disable-line no-unused-expressions
import(/* webpackMode: "eager" */ './test_utils/');
}
document.addEventListener('beforeunload', () => {
......
import ZenMode from '~/zen_mode';
import GLForm from '~/gl_form';
export default function ($formEl) {
export default function initProjectForm($formEl) {
new ZenMode(); // eslint-disable-line no-new
new GLForm($formEl); // eslint-disable-line no-new
}
......@@ -16,7 +16,7 @@ import initInviteMemberModal from '~/invite_member/init_invite_member_modal';
import { IssuableType } from '~/issuable_show/constants';
export default function () {
export default function initShowIssue() {
const initialDataEl = document.getElementById('js-issuable-app');
const { issueType, ...issuableData } = parseIssuableData(initialDataEl);
......
......@@ -10,7 +10,7 @@ import initInviteMemberTrigger from '~/invite_member/init_invite_member_trigger'
import initInviteMemberModal from '~/invite_member/init_invite_member_modal';
import StatusBox from '~/merge_request/components/status_box.vue';
export default function () {
export default function initMergeRequestShow() {
new ZenMode(); // eslint-disable-line no-new
initIssuableSidebar();
initPipelines();
......
......@@ -77,7 +77,7 @@ const createTestDetails = () => {
});
};
export default async function () {
export default async function initPipelineDetailsBundle() {
createTestDetails();
createDagApp();
......
import Vue from 'vue';
import NewProjectCreationApp from './components/app.vue';
export default function (el, props) {
export default function initNewProjectCreation(el, props) {
return new Vue({
el,
components: {
......
......@@ -60,8 +60,8 @@ export default {
const nextItemEl = itemEl.nextElementSibling;
return {
beforeId: prevItemEl && parseInt(prevItemEl.dataset.orderingId, 0),
afterId: nextItemEl && parseInt(nextItemEl.dataset.orderingId, 0),
beforeId: prevItemEl && parseInt(prevItemEl.dataset.orderingId, 10),
afterId: nextItemEl && parseInt(nextItemEl.dataset.orderingId, 10),
};
},
reordered(event) {
......
......@@ -86,7 +86,7 @@ const createValidator = (context, feedbackMap) => ({ el, reportInvalidInput = fa
* @param {Object<string, { message: string, isValid: ?function}>} customFeedbackMap
* @returns {{ inserted: function, update: function }} validateDirective
*/
export default function (customFeedbackMap = {}) {
export default function initValidation(customFeedbackMap = {}) {
const feedbackMap = merge(defaultFeedbackMap, customFeedbackMap);
const elDataMap = new WeakMap();
......
import BoardsListSelector from './boards_list_selector/index';
export default function () {
export default function initAssigneesListSelector() {
const $addListEl = document.querySelector('#js-add-list');
return new BoardsListSelector({
propsData: {
......
import BoardsListSelector from './boards_list_selector';
export default function () {
export default function initMilestoneListSelector() {
const $addListEl = document.querySelector('#js-add-list');
return new BoardsListSelector({
propsData: {
......
......@@ -23,7 +23,7 @@ const disableMergeTrains = () => {
mergeTrainsCheckbox.checked = false;
};
export default function () {
export default function initMergeOptions() {
const { projectFullPath } = containerEl.dataset;
const defaultClient = createDefaultClient();
......
import $ from 'jquery';
import Tracking from '~/tracking';
export default function (assigneeDropdown) {
export default function initTrackInviteMembers(assigneeDropdown) {
const trackEvent = 'show_invite_members';
const trackLabel = 'edit_assignee';
......
......@@ -90,7 +90,7 @@ export default () => {
allowSubEpics: parseBoolean(dataset.allowSubEpics),
defaultInnerHeight: Number(dataset.innerHeight),
isChildEpics: parseBoolean(dataset.childEpics),
currentGroupId: parseInt(dataset.groupId, 0),
currentGroupId: parseInt(dataset.groupId, 10),
basePath: dataset.epicsPath,
fullPath: dataset.fullPath,
epicIid: dataset.iid,
......
import CEGetStateKey from '~/vue_merge_request_widget/stores/get_state_key';
import { stateKey } from './state_maps';
export default function () {
export default function getStateKey() {
if (this.isGeoSecondaryNode) {
return 'geoSecondaryNode';
}
......
......@@ -6,7 +6,7 @@ import { getIdFromGraphQLId } from '~/graphql_shared/utils';
Vue.use(VueApollo);
export default function () {
export default function initIterationsDropdownBundle() {
const el = document.querySelector('#js-iteration-dropdown');
const iterationField = document.getElementById('issue_iteration_id');
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment