You can avoid this by reading the global variable explicitly from the window object, for example: const $ = window.$; This makes it obvious you are using a global variable intentionally rather than because of a typo. Alternatively, you can force the linter to ignore any line by adding //...