weareinreach / InReach

Prefer var declarations be placed at the top of their scope JS-0102
Anti-pattern
Minor
8 days ago2 years old
All 'var' declarations must be at the top of the function scope
30}
31declare global {
32	// eslint-disable-next-line no-var
33	var crowdinOta: { common: OtaClient; database: OtaClient } | undefined34}
35const { crowdinDistTimestamp, fetchCrowdinDbKey, fetchCrowdinFile } = createCommonFns(crowdinOta)
36
All 'var' declarations must be at the top of the function scope
26}
27declare global {
28	// eslint-disable-next-line no-var
29	var crowdinEdgeOta: { common: OtaClient; database: OtaClient } | undefined30}
31
32const { crowdinDistTimestamp, fetchCrowdinDbKey, fetchCrowdinFile } = createCommonFns(crowdinEdgeOta)
All 'var' declarations must be at the top of the function scope
17}
18declare global {
19	// eslint-disable-next-line no-var
20	var crowdinApi: Crowdin | undefined21}
22export const {
23	addSingleKey,
All 'var' declarations must be at the top of the function scope
13
14declare global {
15	// eslint-disable-next-line no-var -- allow global `var` declarations
16	var prisma: PrismaClient<typeof clientOptions> | undefined17}
18
19const clientOptions = {
All 'var' declarations must be at the top of the function scope
17	global.crowdinEdge = crowdinEdge
18}
19declare global {
20	var crowdinEdge: Crowdin | undefined21}
22export const { getStringIdByKey } = createCommonFns(crowdinEdge)
23export { branches, sourceFiles, projectId } from '../constants'