diff options
author | Evan Read <eread@gitlab.com> | 2020-10-06 03:42:35 +0300 |
---|---|---|
committer | Evan Read <eread@gitlab.com> | 2020-10-06 03:42:35 +0300 |
commit | b84d6c397db31bc460678566326b706d197e5ffe (patch) | |
tree | 25e6877cf9d843b0773c1130a645176c968f6ba6 /content | |
parent | 2d185784804a31a2a66de96def94c65543c0058b (diff) |
Upgrade Prettier library and fix warnings that result
Diffstat (limited to 'content')
-rw-r--r-- | content/frontend/404/404.js | 2 | ||||
-rw-r--r-- | content/frontend/default/components/table_of_contents_list.vue | 2 | ||||
-rw-r--r-- | content/frontend/search/index.js | 2 | ||||
-rw-r--r-- | content/frontend/shared/components/gl_icon.vue | 4 | ||||
-rw-r--r-- | content/frontend/shared/dom.js | 4 | ||||
-rw-r--r-- | content/frontend/shared/toc/parse_toc.js | 4 |
6 files changed, 9 insertions, 9 deletions
diff --git a/content/frontend/404/404.js b/content/frontend/404/404.js index 69ef99565..279b58292 100644 --- a/content/frontend/404/404.js +++ b/content/frontend/404/404.js @@ -6,7 +6,7 @@ document.addEventListener('DOMContentLoaded', () => { 'offline-versions', ).dataset; const location = window.location.href; - const isOffline = offlineVersions.split(',').find(version => location.includes(version)); + const isOffline = offlineVersions.split(',').find((version) => location.includes(version)); return new Vue({ el: '#js-error-message', diff --git a/content/frontend/default/components/table_of_contents_list.vue b/content/frontend/default/components/table_of_contents_list.vue index 5e97fad29..7fe874f8f 100644 --- a/content/frontend/default/components/table_of_contents_list.vue +++ b/content/frontend/default/components/table_of_contents_list.vue @@ -14,7 +14,7 @@ export default { }, computed: { allItems() { - return this.items.map(item => { + return this.items.map((item) => { const level = this.level + (item.level || 0); return { diff --git a/content/frontend/search/index.js b/content/frontend/search/index.js index 881b2c830..e985a4d19 100644 --- a/content/frontend/search/index.js +++ b/content/frontend/search/index.js @@ -22,7 +22,7 @@ document.addEventListener('DOMContentLoaded', () => { routing: { stateMapping: singleIndex('gitlab'), }, - searchFunction: helper => { + searchFunction: (helper) => { if (helper.state.query === '') { return; } diff --git a/content/frontend/shared/components/gl_icon.vue b/content/frontend/shared/components/gl_icon.vue index 79b473e39..73bd01241 100644 --- a/content/frontend/shared/components/gl_icon.vue +++ b/content/frontend/shared/components/gl_icon.vue @@ -5,7 +5,7 @@ import { iconSizeOptions } from '../constants'; let iconValidator = () => true; const { icons } = data; -iconValidator = value => { +iconValidator = (value) => { if (icons.includes(value)) { return true; } @@ -33,7 +33,7 @@ export default { type: Number, required: false, default: 16, - validator: value => iconSizeOptions.includes(value), + validator: (value) => iconSizeOptions.includes(value), }, className: { type: String, diff --git a/content/frontend/shared/dom.js b/content/frontend/shared/dom.js index d041ac09a..70a075466 100644 --- a/content/frontend/shared/dom.js +++ b/content/frontend/shared/dom.js @@ -9,7 +9,7 @@ * * @param {Element} el */ -export const getOuterHeight = el => $(el).outerHeight(); +export const getOuterHeight = (el) => $(el).outerHeight(); /** * Find the first child of the given element with the given tag name @@ -19,4 +19,4 @@ export const getOuterHeight = el => $(el).outerHeight(); * @returns {Element | null} Returns first child that matches the given tagName (or null if not found) */ export const findChildByTagName = (el, tagName) => - Array.from(el.childNodes).find(x => x.tagName === tagName.toUpperCase()); + Array.from(el.childNodes).find((x) => x.tagName === tagName.toUpperCase()); diff --git a/content/frontend/shared/toc/parse_toc.js b/content/frontend/shared/toc/parse_toc.js index fa1e3c513..fe4341c94 100644 --- a/content/frontend/shared/toc/parse_toc.js +++ b/content/frontend/shared/toc/parse_toc.js @@ -16,14 +16,14 @@ const TAG_UL = 'UL'; * * @param {Element} menu Parent <ul> element */ -export const parseTOC = menu => { +export const parseTOC = (menu) => { const items = []; if (!menu) { return items; } - menu.childNodes.forEach(li => { + menu.childNodes.forEach((li) => { if (li.tagName !== TAG_LI) { return; } |