Update typescript to latest (v4.5.5)
Vector's tsc version is currently reporting errors that the latest typescript version doesn't report and vice versa. Upgrade to the latest version to avoid these discrepancies. Additionally: Fix tsc errors that are now reported by updated version Bug: T297614 Change-Id: I0eb67bcc1a5ce214fcf2d6f6433a5de3a845b6a6
This commit is contained in:
parent
26835ad0ce
commit
76eb7caa2f
File diff suppressed because it is too large
Load Diff
|
@ -35,7 +35,7 @@
|
||||||
"pre-commit": "1.2.2",
|
"pre-commit": "1.2.2",
|
||||||
"stylelint-config-wikimedia": "0.11.1",
|
"stylelint-config-wikimedia": "0.11.1",
|
||||||
"svgo": "2.3.1",
|
"svgo": "2.3.1",
|
||||||
"typescript": "3.8.3",
|
"typescript": "4.5.5",
|
||||||
"vue": "2.6.11"
|
"vue": "2.6.11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
/** See Vector\Hooks::getVectorResourceLoaderConfig */
|
/** See Vector\Hooks::getVectorResourceLoaderConfig */
|
||||||
interface VectorResourceLoaderVirtualConfig {
|
interface VectorResourceLoaderVirtualConfig {
|
||||||
|
wgVectorSearchHost: string;
|
||||||
/**
|
/**
|
||||||
* The name of the ResourceLoader module that contains search.
|
* The name of the ResourceLoader module that contains search.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -16,7 +16,9 @@ var /** @type {VectorResourceLoaderVirtualConfig} */
|
||||||
CAN_TEST_SEARCH = !!(
|
CAN_TEST_SEARCH = !!(
|
||||||
window.performance &&
|
window.performance &&
|
||||||
/* eslint-disable compat/compat */
|
/* eslint-disable compat/compat */
|
||||||
|
// @ts-ignore
|
||||||
performance.mark &&
|
performance.mark &&
|
||||||
|
// @ts-ignore
|
||||||
performance.measure &&
|
performance.measure &&
|
||||||
performance.getEntriesByName ),
|
performance.getEntriesByName ),
|
||||||
/* eslint-enable compat/compat */
|
/* eslint-enable compat/compat */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* global FetchEndEvent, SuggestionClickEvent, SubmitEvent */
|
/* global FetchEndEvent, SuggestionClickEvent, SearchSubmitEvent */
|
||||||
/** @module Instrumentation */
|
/** @module Instrumentation */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -13,10 +13,14 @@ var INPUT_LOCATION_MOVED = 'header-moved',
|
||||||
// mediawiki.searchSuggest performance. Marks and Measures will only be
|
// mediawiki.searchSuggest performance. Marks and Measures will only be
|
||||||
// recorded on the Vector skin and only if browser supported.
|
// recorded on the Vector skin and only if browser supported.
|
||||||
shouldTestSearchPerformance = !!( window.performance &&
|
shouldTestSearchPerformance = !!( window.performance &&
|
||||||
|
// @ts-ignore
|
||||||
window.requestAnimationFrame &&
|
window.requestAnimationFrame &&
|
||||||
/* eslint-disable compat/compat */
|
/* eslint-disable compat/compat */
|
||||||
|
// @ts-ignore
|
||||||
performance.mark &&
|
performance.mark &&
|
||||||
|
// @ts-ignore
|
||||||
performance.measure &&
|
performance.measure &&
|
||||||
|
// @ts-ignore
|
||||||
performance.getEntriesByName &&
|
performance.getEntriesByName &&
|
||||||
performance.clearMarks ),
|
performance.clearMarks ),
|
||||||
/* eslint-enable compat/compat */
|
/* eslint-enable compat/compat */
|
||||||
|
@ -88,7 +92,7 @@ function onFetchEnd( event ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {SuggestionClickEvent|SubmitEvent} event
|
* @param {SuggestionClickEvent|SearchSubmitEvent} event
|
||||||
*/
|
*/
|
||||||
function onSuggestionClick( event ) {
|
function onSuggestionClick( event ) {
|
||||||
mw.track( 'mediawiki.searchSuggest', {
|
mw.track( 'mediawiki.searchSuggest', {
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {SuggestionClickEvent} SubmitEvent
|
* @typedef {SuggestionClickEvent} SearchSubmitEvent
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* exported SuggestionClickEvent, SubmitEvent, FetchEndEvent */
|
/* exported SuggestionClickEvent, SuggestionSubmitEvent, FetchEndEvent */
|
||||||
|
|
Loading…
Reference in New Issue