Do not use "@ts-ignore" because it alters compilation errors
186 }
187
188 public sub(filters: any[], onEvent: (event: Event, isAfterEose: boolean, relayUrl: string | undefined) => void, maxDelayms = 100) {
189 // @ts-ignore190 return this.relays.subscribe(filters, this.getCurrentRelaysInArray(), onEvent, maxDelayms, undefined)
191 }
192}
Description
TypeScript provides several directive comments that can be used to alter how it processes files. Using these to suppress TypeScript Compiler Errors reduces the effectiveness of TypeScript overall.
However, if you must keep them, you can add an explanation next to your directives.
The directive comments supported by TypeScript are:
// @ts-expect-error
// @ts-ignore
// @ts-nocheck
// @ts-check
Bad Practice
// @ts-ignore
user.login()
Recommended
// @ts-ignore - this is ok because <reason>
user.login()