/
bearury
/
ui-kit-ce
Обзор
Документация
Войти
/
bearury
/
ui-kit-ce
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
develop
packages/styler-sync/src/utils/ConnectionErrorManager.ts
24 строки
709 B
Урядышев Павел Александрович
chore: устранены предупреждения eslint
25 июл 2025, 14:03
25 июл 2025, 14:03
1bad2f7
Код
Авторство
О чём код?
import { ThemeProviderId } from '../types' type ErrorsCount = Record<ThemeProviderId, number> export class ConnectionErrorManager { private errorsCount: ErrorsCount = {} // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types incrementError(id: ThemeProviderId) { if (!this.errorsCount[id]) { return (this.errorsCount[id] = 1) } return ++this.errorsCount[id] } // eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types resetErrorCount(id: ThemeProviderId) { this.errorsCount[id] = 0 } } export const pingOverridesErrorsManager = new ConnectionErrorManager() export const fullThemeErrorsManager = new ConnectionErrorManager()