Update typescript-eslint monorepo to v8 (major) (#31231)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renaud Chaput <renchap@gmail.com>
This commit is contained in:
renovate[bot] 2024-09-11 15:59:46 +02:00 committed by GitHub
parent 2babfafaff
commit a27f7f4e56
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 99 additions and 77 deletions

View file

@ -65,7 +65,7 @@ export const synchronouslySubmitMarkers = createAppAsyncThunk(
client.setRequestHeader('Content-Type', 'application/json');
client.setRequestHeader('Authorization', `Bearer ${accessToken}`);
client.send(JSON.stringify(params));
} catch (e) {
} catch {
// Do not make the BeforeUnload handler error out
}
},

View file

@ -151,7 +151,7 @@ async function refreshHomeTimelineAndNotification(dispatch, getState) {
// TODO: polling for merged notifications
try {
await dispatch(pollRecentGroupNotifications());
} catch (error) {
} catch {
// TODO
}
} else {

View file

@ -5,7 +5,7 @@ export function start() {
try {
Rails.start();
} catch (e) {
} catch {
// If called twice
}
}

View file

@ -60,8 +60,8 @@ export default class ErrorBoundary extends PureComponent {
try {
textarea.select();
document.execCommand('copy');
} catch (e) {
} catch {
// do nothing
} finally {
document.body.removeChild(textarea);
}

View file

@ -131,7 +131,7 @@ class LoginForm extends React.PureComponent {
try {
new URL(url);
return true;
} catch(_) {
} catch {
return false;
}
};

View file

@ -319,8 +319,8 @@ class UI extends PureComponent {
try {
e.dataTransfer.dropEffect = 'copy';
} catch (err) {
} catch {
// do nothing
}
return false;

View file

@ -17,7 +17,7 @@ function onProviderError(error: unknown) {
error &&
typeof error === 'object' &&
error instanceof Error &&
error.message.match('MISSING_DATA')
/MISSING_DATA/.exec(error.message)
) {
console.warn(error.message);
}

View file

@ -14,7 +14,7 @@ export default class Settings {
const encodedData = JSON.stringify(data);
localStorage.setItem(key, encodedData);
return data;
} catch (e) {
} catch {
return null;
}
}
@ -24,7 +24,7 @@ export default class Settings {
try {
const rawData = localStorage.getItem(key);
return JSON.parse(rawData);
} catch (e) {
} catch {
return null;
}
}
@ -35,7 +35,8 @@ export default class Settings {
const key = this.generateKey(id);
try {
localStorage.removeItem(key);
} catch (e) {
} catch {
// ignore if the key is not found
}
}
return data;

View file

@ -30,7 +30,7 @@ function isActionWithmaybeAlertParams(
return isAction(action);
}
// eslint-disable-next-line @typescript-eslint/ban-types -- we need to use `{}` here to ensure the dispatch types can be merged
// eslint-disable-next-line @typescript-eslint/no-empty-object-type -- we need to use `{}` here to ensure the dispatch types can be merged
export const errorsMiddleware: Middleware<{}, RootState> =
({ dispatch }) =>
(next) =>

View file

@ -51,7 +51,7 @@ const play = (audio: HTMLAudioElement) => {
};
export const soundsMiddleware = (): Middleware<
// eslint-disable-next-line @typescript-eslint/ban-types -- we need to use `{}` here to ensure the dispatch types can be merged
// eslint-disable-next-line @typescript-eslint/no-empty-object-type -- we need to use `{}` here to ensure the dispatch types can be merged
{},
RootState
> => {